jenkinsci / xray-connector-plugin

Xray Test Management Connector for Jenkins
https://plugins.jenkins.io/xray-connector/
MIT License
16 stars 13 forks source link

Log the http status code of the connection test #56

Closed joerg1985 closed 2 years ago

joerg1985 commented 2 years ago

The current log message of the connection test does not show the status code of the connection test. This makes it hard to find the real issue, like is it authentication, firewall configuration, etc.

e.g. a current log line Dec 17, 2021 9:15:29 AM SEVERE com.xpandit.plugins.xrayjenkins.model.ServerConfiguration jiraServerTestConnection URL provided is not from a Jira instance -> https://.../rest/api/2/serverInfo didn't return a valid result.

Adding the http status code to the log line could help finding the real issue

e.g. a log line pointing to an authentication issue Dec 17, 2021 9:15:29 AM SEVERE com.xpandit.plugins.xrayjenkins.model.ServerConfiguration jiraServerTestConnection URL provided is not from a Jira instance -> https://.../rest/api/2/serverInfo didn't return a valid result, http status code 401.

e.g. a log line pointing to an firewall issue Dec 17, 2021 9:15:29 AM SEVERE com.xpandit.plugins.xrayjenkins.model.ServerConfiguration jiraServerTestConnection URL provided is not from a Jira instance -> https://.../rest/api/2/serverInfo didn't return a valid result, http status code 403.

Russell616 commented 2 years ago

Hi everyone!

I just wanted to let you know that we just release Xray-connector 2.6.0 with this issue is implemented.