Description
With CURATOR-228 NoAuth response code is logged in the PersistentNode recipe if the client has no authorisation to create the node. However it can happen that the "create" permission has been given, but not "write" persmission, so further setData calls fail silently. I know this is a client error and the permissions should be fixed, but we would like to give better visibility to our users if they face this issue. Since we don't have access to the background callback within the recipe I thought logging the unexpected response code would be useful.
This method could be called from the background callback.
private void logUnexecpedResponseCode(int responseCode) { Code code = Code.get(responseCode); log.warn("Client received unexpected response code '{}' while creating/writing node on path {}', code, getActualPath()); }
Attachments
Issue Links
- links to