-
Notifications
You must be signed in to change notification settings - Fork 3.6k
Enable Error Prone check: FormatStringAnnotation #9512
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -119,7 +119,7 @@ private Optional<Map<String, Object>> getAccessToken(ContainerRequestContext req | |
| return service.convertTokenToClaims(accessToken.get()); | ||
|
||
| } | ||
| catch (JwtException | IllegalArgumentException e) { | ||
| LOG.debug("Unable to parse JWT token: " + e.getMessage(), e); | ||
| LOG.debug(e, "Unable to parse JWT token"); | ||
| } | ||
| } | ||
| return Optional.empty(); | ||
|
|
||
| Original file line number | Diff line number | Diff line change | ||||||
|---|---|---|---|---|---|---|---|---|
|
|
@@ -128,8 +128,7 @@ private static void copyTable( | |||||||
| break; | ||||||||
| } | ||||||||
|
|
||||||||
| LOG.info("Running import for %s", target, sql); | ||||||||
| LOG.info("%s", sql); | ||||||||
| LOG.info("Running import for %s%n%s", target, sql); | ||||||||
|
||||||||
| LOG.info("Running import for %s%n%s", target, sql); | |
| LOG.info("Running import for %s", target); | |
| LOG.info("Query %s", sql); |
Maybe
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That would be a more straightforward transformation, sure, but I think that if they are two separate logs then they may get separated in the output if there are concurrent threads. Perhaps this merging can be done in a separate commit, though.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -316,7 +316,7 @@ public void close() | |
| } | ||
| catch (Exception e) { | ||
| // ignore | ||
| LOG.debug("Error clearing scroll", e); | ||
| LOG.debug(e, "Error clearing scroll"); | ||
|
||
| } | ||
| } | ||
| } | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Don't you need to add
@FormatStringto airlift logger methods?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There's already one, and that's how we can find all these issues here: