[jboss-jira] [JBoss JIRA] (WFWIP-280) Warnings propagated from io.smallrye.jwt.auth.* don't have assigned ID

Darran Lofthouse (Jira) issues at jboss.org
Wed Dec 11 07:24:00 EST 2019


    [ https://issues.redhat.com/browse/WFWIP-280?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13823841#comment-13823841 ] 

Darran Lofthouse commented on WFWIP-280:
----------------------------------------

[~jkasik]

I agree the error messages are very valuable which is why I have agreed to see if the SmallRye JWT project will accept using them, but this is one of the costs of using third party libraries over our own - we loose the ability to enforce our own logging standards over them.

Regarding the text you are quoting, that includes the word "caught", it is not the most descriptive chunks of text but if we are talking about something being "caught" in Java it would imply it has previously been thrown - i.e. an Exception or other Throwable.  

If we have cases of exceptions being caught by our code and subsequently logged or rethrown by our code I 100% agree we should be logging or rethrowing with a message ID, generally code that doesn't do this correctly should fail code review.

But the message that has led to this WFWIP issue is not thrown by SmallRye JWT and so it not "caught" by our code, the quoted message is directly logged by SmallRye JWT.

So the plan we will take will be to see if SmallRye JWT will accept IDs being added to their messages.  This specific message however will likely be dropped to DEBUG or TRACE level anyway or I will see if it can be moved to a per-request logging category instead.


> Warnings propagated from io.smallrye.jwt.auth.* don't have assigned ID
> ----------------------------------------------------------------------
>
>                 Key: WFWIP-280
>                 URL: https://issues.redhat.com/browse/WFWIP-280
>             Project: WildFly WIP
>          Issue Type: Bug
>          Components: MP JWT
>            Reporter: Jan Kasik
>            Assignee: Darran Lofthouse
>            Priority: Critical
>
> Warning which are propagated to log from io.smallrye.jwt.auth package don't have assigned logging ID.
> Example:
> {code}
> 11:52:50,705 WARN  [io.smallrye.jwt.auth.mechanism.JWTHttpAuthenticationMechanism] (default task-1) Unable to validate bearer token: Failed to verify token: io.smallrye.jwt.auth.principal.ParseException: Failed to verify token
> {code}



--
This message was sent by Atlassian Jira
(v7.13.8#713008)


More information about the jboss-jira mailing list