Interface JsonInErrorMessageSanitizer


  • public interface JsonInErrorMessageSanitizer
    Customize / sanitize the JSON before putting it in the stack trace / error messages. Mainly thought to avoid leaking secrets / credentials in the log.
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      net.sf.json.JSONObject sanitize​(net.sf.json.JSONObject jsonData)
      Removes/redacts all the confidential information to let the result to be printed in the log / stack trace / error message.
    • Field Detail

      • NOOP

        static final JsonInErrorMessageSanitizer NOOP
        Used by default when no other sanitizer are configured. Has no effect on the information, just returning a copy.
    • Method Detail

      • sanitize

        net.sf.json.JSONObject sanitize​(net.sf.json.JSONObject jsonData)
        Removes/redacts all the confidential information to let the result to be printed in the log / stack trace / error message. Must return a new instance of the JSON.