Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-55890

RocketChat notification (using proxy) fails since version 1.3.1

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • None

      Since plugin version 1.3.1 sending messages to our RocketChat Server fails (via proxy without proxy credentials)

      Reverting to version 1.3.0 fix the problem.
      Patching the plugin by deleting new line 97 in RocketChatClientCallBuilder (which was introduced in version 1.3.1 ), fix it as well.

      Error messages

      Console Output of the Jenkins pipeline

      TIME [WARN] Sending Rocketchat message failed: Please check if the server API https://ROCKET_CHAT_FQDN/api/v1/login is correct: org.apache.http.conn.HttpHostConnectException: Connect to ROCKET_CHAT_FQDN:443 [ROCKET_CHAT_FQDN/ROCKET_CHAT_IP] failed: Connection refused (Connection refused)
      

      Stack trace:

      jenkins.plugins.rocketchatnotifier.rocket.errorhandling.RocketClientException: Please check if the server API https://ROCKET_CHAT_FQDN/api/v1/login is correct: org.apache.http.conn.HttpHostConnectException: Connect to ROCKET_CHAT_FQDN:443 [ROCKET_CHAT_FQDN/ROCKET_CHAT_IP] failed: Connection refused (Connection refused)
      	at jenkins.plugins.rocketchatnotifier.rocket.RocketChatBasicCallAuthentication.doAuthentication(RocketChatBasicCallAuthentication.java:53)
      	at jenkins.plugins.rocketchatnotifier.rocket.RocketChatClientCallBuilder.buildCall(RocketChatClientCallBuilder.java:121)
      	at jenkins.plugins.rocketchatnotifier.rocket.RocketChatClientCallBuilder.buildCall(RocketChatClientCallBuilder.java:111)
      	at jenkins.plugins.rocketchatnotifier.rocket.RocketChatClientImpl.getChannels(RocketChatClientImpl.java:90)
      	at jenkins.plugins.rocketchatnotifier.RocketClientImpl.<init>(RocketClientImpl.java:30)
      	at jenkins.plugins.rocketchatnotifier.workflow.RocketSendStep$RocketSendStepExecution.getRocketClient(RocketSendStep.java:249)
      	at jenkins.plugins.rocketchatnotifier.workflow.RocketSendStep$RocketSendStepExecution.run(RocketSendStep.java:225)
      	at jenkins.plugins.rocketchatnotifier.workflow.RocketSendStep$RocketSendStepExecution.run(RocketSendStep.java:181)
      	at org.jenkinsci.plugins.workflow.steps.AbstractSynchronousNonBlockingStepExecution$1$1.call(AbstractSynchronousNonBlockingStepExecution.java:47)
      	at hudson.security.ACL.impersonate(ACL.java:290)
      	at org.jenkinsci.plugins.workflow.steps.AbstractSynchronousNonBlockingStepExecution$1.run(AbstractSynchronousNonBlockingStepExecution.java:44)
      	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
      	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
      	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
      	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
      	at java.lang.Thread.run(Thread.java:748)
      Caused by: com.mashape.unirest.http.exceptions.UnirestException: org.apache.http.conn.HttpHostConnectException: Connect to ROCKET_CHAT_FQDN:443 [ROCKET_CHAT_FQDN/ROCKET_CHAT_IP] failed: Connection refused (Connection refused)
      	at com.mashape.unirest.http.HttpClientHelper.request(HttpClientHelper.java:143)
      	at com.mashape.unirest.request.BaseRequest.asJson(BaseRequest.java:68)
      	at jenkins.plugins.rocketchatnotifier.rocket.RocketChatBasicCallAuthentication.doAuthentication(RocketChatBasicCallAuthentication.java:50)
      	... 15 more
      Caused by: org.apache.http.conn.HttpHostConnectException: Connect to ROCKET_CHAT_FQDN:443 [ROCKET_CHAT_FQDN/ROCKET_CHAT_IP] failed: Connection refused (Connection refused)
      	at org.apache.http.impl.conn.DefaultHttpClientConnectionOperator.connect(DefaultHttpClientConnectionOperator.java:159)
      	at org.apache.http.impl.conn.PoolingHttpClientConnectionManager.connect(PoolingHttpClientConnectionManager.java:373)
      	at org.apache.http.impl.execchain.MainClientExec.establishRoute(MainClientExec.java:381)
      	at org.apache.http.impl.execchain.MainClientExec.execute(MainClientExec.java:237)
      	at org.apache.http.impl.execchain.ProtocolExec.execute(ProtocolExec.java:185)
      	at org.apache.http.impl.execchain.RetryExec.execute(RetryExec.java:89)
      	at org.apache.http.impl.execchain.RedirectExec.execute(RedirectExec.java:111)
      	at org.apache.http.impl.client.InternalHttpClient.doExecute(InternalHttpClient.java:185)
      	at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:83)
      	at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:108)
      	at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:56)
      	at com.mashape.unirest.http.HttpClientHelper.request(HttpClientHelper.java:138)
      	... 17 more
      Caused by: java.net.ConnectException: Connection refused (Connection refused)
      	at java.net.PlainSocketImpl.socketConnect(Native Method)
      	at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:350)
      	at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:206)
      	at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:188)
      	at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)
      	at java.net.Socket.connect(Socket.java:589)
      	at org.apache.http.conn.ssl.SSLConnectionSocketFactory.connectSocket(SSLConnectionSocketFactory.java:339)
      	at org.apache.http.impl.conn.DefaultHttpClientConnectionOperator.connect(DefaultHttpClientConnectionOperator.java:142)
      	... 28 more
      

            mreinhardt Martin Reinhardt
            uhanisch Uwe Hanisch
            Votes:
            2 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: