Skip to content

Conversation

@eschmidtfds
Copy link
Contributor

@eschmidtfds eschmidtfds commented Aug 3, 2022

Description

  • adds logging of the access-token request and its response for troubleshooting purposes
  • chose 'trace' as the log level in an attempt to lower the risk of this being enabled in production
  • chose to log the data in one line instead of multiple lines, to avoid issues with logging tools that only support one line per log message, however the response is logged as-is.
  • Note: removed sl4fj-simple from the dependencies
    • on the one hand it clashed with the logback test-dependency I use for intercepting logs during tests
      (sl4fj complaining about multiple bindings being available)
    • on the other hand we also should not ship with a binding at all and instead leave that choice to the user.
    • One caveat now is that SLF4J will print this warning on stderr if a user adds our lib without also adding a slf4j-binding:
      SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder".
      SLF4J: Defaulting to no-operation (NOP) logger implementation
      SLF4J: See http://www.slf4j.org/codes.html#StaticLoggerBinder for further details.
      
    • why logback over slf4j-simple: had an easier time configuring logback to suppress logs other than the one i need during a test run

Links

Testing

Checklist

Ensure the following things have been met before requesting a review:

  • Follows all project developer guide and coding standards.
  • Tests have been written for the change, when applicable.
  • Confidential information (credentials, auth tokens, etc...) is not included.

@eschmidtfds eschmidtfds requested a review from a team as a code owner August 3, 2022 16:41
@CLAassistant
Copy link

CLAassistant commented Aug 3, 2022

CLA assistant check
All committers have signed the CLA.

@eschmidtfds eschmidtfds force-pushed the chore/logging/add-access-token-debug-logging branch from 8731e84 to 323201f Compare August 3, 2022 17:24
mima0815
mima0815 previously approved these changes Aug 5, 2022
@eschmidtfds eschmidtfds force-pushed the chore/logging/add-access-token-debug-logging branch from 323201f to 318893e Compare August 5, 2022 16:59
@eschmidtfds eschmidtfds merged commit 423ed92 into main Aug 16, 2022
@eschmidtfds eschmidtfds deleted the chore/logging/add-access-token-debug-logging branch August 16, 2022 22:14
@dgawande12 dgawande12 mentioned this pull request May 3, 2023
3 tasks
dgawande12 added a commit that referenced this pull request May 4, 2023
#### Release 1.0.1.

-  updated dependencies to latest stable versions
- `org.json:json` from 20220320 to 20230227 -  important dependency update which fixes the sonatype security threat
- Documentation update
- adds logging of the access-token request and its response for troubleshooting purposes [#34](#34)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants