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

Failed to notify status of build to bitbucket in Multibranch pipeline and to trigger build from bitbucket when code pushed

    Details

    • Similar Issues:

      Description

      Failed to notify status of build to bitbucket in Multibranch pipeline and to trigger build from bitbucket when code pushed,

      error message 

      [Bitbucket] Notifying pull request build result
      ERROR: Could not send notifications
      java.io.IOException: Communication error
      	at com.cloudbees.jenkins.plugins.bitbucket.client.BitbucketCloudApiClient.doRequest(BitbucketCloudApiClient.java:861)
      	at com.cloudbees.jenkins.plugins.bitbucket.client.BitbucketCloudApiClient.postRequest(BitbucketCloudApiClient.java:902)
      	at com.cloudbees.jenkins.plugins.bitbucket.client.BitbucketCloudApiClient.postBuildStatus(BitbucketCloudApiClient.java:607)
      	at com.cloudbees.jenkins.plugins.bitbucket.BitbucketChangesetCommentNotifier.buildStatus(BitbucketChangesetCommentNotifier.java:50)
      	at com.cloudbees.jenkins.plugins.bitbucket.BitbucketBuildStatusNotifications.createStatus(BitbucketBuildStatusNotifications.java:143)
      	at com.cloudbees.jenkins.plugins.bitbucket.BitbucketBuildStatusNotifications.sendNotifications(BitbucketBuildStatusNotifications.java:185)
      	at com.cloudbees.jenkins.plugins.bitbucket.BitbucketBuildStatusNotifications.access$000(BitbucketBuildStatusNotifications.java:60)
      	at com.cloudbees.jenkins.plugins.bitbucket.BitbucketBuildStatusNotifications$JobCompletedListener.onCompleted(BitbucketBuildStatusNotifications.java:257)
      	at hudson.model.listeners.RunListener.fireCompleted(RunListener.java:209)
      	at org.jenkinsci.plugins.workflow.job.WorkflowRun.finish(WorkflowRun.java:584)
      	at org.jenkinsci.plugins.workflow.job.WorkflowRun.access$1000(WorkflowRun.java:133)
      	at org.jenkinsci.plugins.workflow.job.WorkflowRun$GraphL.onNewHead(WorkflowRun.java:996)
      	at org.jenkinsci.plugins.workflow.cps.CpsFlowExecution.notifyListeners(CpsFlowExecution.java:1463)
      	at org.jenkinsci.plugins.workflow.cps.CpsThreadGroup$3.run(CpsThreadGroup.java:458)
      	at org.jenkinsci.plugins.workflow.cps.CpsVmExecutorService$1.run(CpsVmExecutorService.java:37)
      	at hudson.remoting.SingleLaneExecutorService$1.run(SingleLaneExecutorService.java:131)
      	at jenkins.util.ContextResettingExecutorService$1.run(ContextResettingExecutorService.java:28)
      	at jenkins.security.ImpersonatingExecutorService$1.run(ImpersonatingExecutorService.java:59)
      	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:1142)
      	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
      	at java.lang.Thread.run(Thread.java:748)
      Caused by: java.net.SocketTimeoutException: Read timed out
      	at java.net.SocketInputStream.socketRead0(Native Method)
      	at java.net.SocketInputStream.socketRead(SocketInputStream.java:116)
      	at java.net.SocketInputStream.read(SocketInputStream.java:171)
      	at java.net.SocketInputStream.read(SocketInputStream.java:141)
      	at sun.security.ssl.InputRecord.readFully(InputRecord.java:465)
      	at sun.security.ssl.InputRecord.read(InputRecord.java:503)
      	at sun.security.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:983)
      	at sun.security.ssl.SSLSocketImpl.readDataRecord(SSLSocketImpl.java:940)
      	at sun.security.ssl.AppInputStream.read(AppInputStream.java:105)
      	at org.apache.http.impl.io.SessionInputBufferImpl.streamRead(SessionInputBufferImpl.java:137)
      	at org.apache.http.impl.io.SessionInputBufferImpl.fillBuffer(SessionInputBufferImpl.java:153)
      	at org.apache.http.impl.io.SessionInputBufferImpl.readLine(SessionInputBufferImpl.java:282)
      	at org.apache.http.impl.conn.DefaultHttpResponseParser.parseHead(DefaultHttpResponseParser.java:138)
      	at org.apache.http.impl.conn.DefaultHttpResponseParser.parseHead(DefaultHttpResponseParser.java:56)
      	at org.apache.http.impl.io.AbstractMessageParser.parse(AbstractMessageParser.java:259)
      	at org.apache.http.impl.DefaultBHttpClientConnection.receiveResponseHeader(DefaultBHttpClientConnection.java:163)
      	at org.apache.http.impl.conn.CPoolProxy.receiveResponseHeader(CPoolProxy.java:165)
      	at org.apache.http.protocol.HttpRequestExecutor.doReceiveResponse(HttpRequestExecutor.java:273)
      	at org.apache.http.protocol.HttpRequestExecutor.execute(HttpRequestExecutor.java:125)
      	at org.apache.http.impl.execchain.MainClientExec.execute(MainClientExec.java:272)
      	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:72)
      	at com.cloudbees.jenkins.plugins.bitbucket.client.BitbucketCloudApiClient.executeMethod(BitbucketCloudApiClient.java:759)
      	at com.cloudbees.jenkins.plugins.bitbucket.client.BitbucketCloudApiClient.doRequest(BitbucketCloudApiClient.java:843)
      	... 22 more
      Finished: SUCCESS
      

        Attachments

          Activity

          Hide
          joaomiranda Joao Miranda added a comment -

          Same problem here. It's very inconvenient!

          Please, anybody got fix this?

           

          Show
          joaomiranda Joao Miranda added a comment - Same problem here. It's very inconvenient! Please, anybody got fix this?  
          Hide
          jbergeron Joshua Bergeron added a comment - - edited

          I have also recently been experiencing this and it has been driving me crazy! It started happening in the last week and has been intermittent - both on the build notification end and build trigger side of things.

           

          Show
          jbergeron Joshua Bergeron added a comment - - edited I have also recently been experiencing this and it has been driving me crazy! It started happening in the last week and has been intermittent - both on the build notification end and build trigger side of things.  
          Hide
          patriks Patrik Schalin added a comment -

          Tried downgrading to no avail.

          Noticed that it was not all my jobs that were failing but only a select few with no useful information in the logs.

          Finally solved it by logging on to the master and forcefully delete the job dirs of the failing jobs and then run the folder scan.

          For the first time since this problem started the re-created jobs actually builds as expected.

          Show
          patriks Patrik Schalin added a comment - Tried downgrading to no avail. Noticed that it was not all my jobs that were failing but only a select few with no useful information in the logs. Finally solved it by logging on to the master and forcefully delete the job dirs of the failing jobs and then run the folder scan. For the first time since this problem started the re-created jobs actually builds as expected.
          Hide
          jbergeron Joshua Bergeron added a comment -

          Gave that a try and the first build after that went well, but subsequent builds have remained inconsistent - sometimes jobs fail to checkout, other times they fail to send the build status notification. Always the same java.io.IOException but not much other helpful information. Doing what I can to investigate on my end but I'm running short of ideas so if anyone has any

          Show
          jbergeron Joshua Bergeron added a comment - Gave that a try and the first build after that went well, but subsequent builds have remained inconsistent - sometimes jobs fail to checkout, other times they fail to send the build status notification. Always the same java.io.IOException but not much other helpful information. Doing what I can to investigate on my end but I'm running short of ideas so if anyone has any
          Show
          alanjcastonguay Alan Castonguay added a comment - - edited Appears to be similar to some of the observations in  https://github.com/jenkinsci/bitbucket-branch-source-plugin/issues/213 - created https://github.com/jenkinsci/bitbucket-branch-source-plugin/issues/217

            People

            • Assignee:
              Unassigned
              Reporter:
              nissim_bitan Nissim Bitan
            • Votes:
              4 Vote for this issue
              Watchers:
              8 Start watching this issue

              Dates

              • Created:
                Updated: