[ 
https://issues.apache.org/jira/browse/CONNECTORS-1697?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Markus Schuch reassigned CONNECTORS-1697:
-----------------------------------------

    Assignee: Markus Schuch

> JIRA Authority spams an WARN with stacktrace for every unknown user to the log
> ------------------------------------------------------------------------------
>
>                 Key: CONNECTORS-1697
>                 URL: https://issues.apache.org/jira/browse/CONNECTORS-1697
>             Project: ManifoldCF
>          Issue Type: Bug
>          Components: JIRA connector
>    Affects Versions: ManifoldCF 2.20
>            Reporter: Markus Schuch
>            Assignee: Markus Schuch
>            Priority: Major
>
> Jira 8 responds with HTTP response Code 404 for unknown users:
> {code:java}
> λ curl -i --cookie "JSESSIONID=******************" 
> https://myjiraserver/rest/api/2/user?username=unkownUser
> HTTP/1.1 404
> ...
> {"errorMessages":["The user named 'unknownUser' does not 
> exist"],"errors":{}{code}
> We allow only 200 OK responses to be processed, every other HTTP Response 
> Code is transformed to a ManifoldCFExcepction and therefore loggt at level 
> WARN with a stack trace
> [https://github.com/apache/manifoldcf/blob/release-2.21/connectors/jira/connector/src/main/java/org/apache/manifoldcf/authorities/authorities/jira/JiraSession.java#L284]
>  
> An unknown user should not produce so much noise in the log
> {code:java}
> 2022-01-26T16:43:37,731 WARN [Auth check thread 2] 
> org.apache.manifoldcf.authorityservice: Authority error: Response exception: 
> Unexpected result code 404: {"errorMessages":["The user named 'johndoe' does 
> not exist"],"errors":{}}
> 2022-01-26T16:43:37.732+01:00    
> org.apache.manifoldcf.core.interfaces.ManifoldCFException: Response 
> exception: Unexpected result code 404: {"errorMessages":["The user named 
> 'johndoe' does not exist"],"errors":{}}
> 2022-01-26T16:43:37.732+01:00    at 
> org.apache.manifoldcf.authorities.authorities.jira.JiraAuthorityConnector.handleResponseException(JiraAuthorityConnector.java:542)
>  ~[mcf-jira-connector.jar:?]
> 2022-01-26T16:43:37.732+01:00    at 
> org.apache.manifoldcf.authorities.authorities.jira.JiraAuthorityConnector.checkUserExists(JiraAuthorityConnector.java:609)
>  ~[mcf-jira-connector.jar:?]
> 2022-01-26T16:43:37.732+01:00    at 
> org.apache.manifoldcf.authorities.authorities.jira.JiraAuthorityConnector.getAuthorizationResponse(JiraAuthorityConnector.java:516)
>  ~[mcf-jira-connector.jar:?]
> 2022-01-26T16:43:37.732+01:00    at 
> org.apache.manifoldcf.authorities.system.AuthCheckThread.run(AuthCheckThread.java:97)
>  [classes/:?]
> 2022-01-26T16:43:37.732+01:00    Caused by: 
> org.apache.manifoldcf.authorities.authorities.jira.ResponseException: 
> Unexpected result code 404: {"errorMessages":["The user named 'johndoe' does 
> not exist"],"errors":{}}
> 2022-01-26T16:43:37.732+01:00    at 
> org.apache.manifoldcf.authorities.authorities.jira.JiraSession.getRest(JiraSession.java:285)
>  ~[mcf-jira-connector.jar:?]
> 2022-01-26T16:43:37.732+01:00    at 
> org.apache.manifoldcf.authorities.authorities.jira.JiraSession.checkUserExists(JiraSession.java:307)
>  ~[mcf-jira-connector.jar:?]
> 2022-01-26T16:43:37.732+01:00    at 
> org.apache.manifoldcf.authorities.authorities.jira.JiraAuthorityConnector$CheckUserExistsThread.run(JiraAuthorityConnector.java:562)
>  ~[mcf-jira-connector.jar:?] {code}



--
This message was sent by Atlassian Jira
(v8.20.1#820001)

Reply via email to