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

Jenkins CLI unable to create job - hudson.cli.DiagnosedStreamCorruptionException

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved (View Workflow)
    • Priority: Trivial
    • Resolution: Not A Defect
    • Component/s: cli, core, remoting
    • Labels:
      None
    • Environment:
      OS: Centos 7.6 / Centos 5.11
      Jenkins: 2.150.2 (Fresh install with recommended plugins)
      Java: Oracle JDK 11.0.2 (Centos 7.6) / JDK 8u202 (Centos 5.11)
    • Similar Issues:

      Description

       

      Hi all, we recently upgraded our Jenkins to 2.150.2 from 1.454. However, our legacy applications are experiencing issues using the Jenkins CLI.

      So, I decided to do some testing with a fresh install of Jenkins both on our current environment (Centos 5.11 - JDK 8u202) and a more up-to-date environment (Centos 7.6 - JDK 11.0.2). Note that this install includes the recommended plugins, as suggested by the first-time setup. I'm running Jenkins as follows:

      java -jar jenkins.war --httpPort=8080
      

      On both instances, I was able to run the following successfully:

      java -jar jenkins-cli.jar -auth user:password -s http://localhost:8080/ help
      

      I then attempted to create a blank job using the following command:

       

      java -jar jenkins-cli.jar -auth user:password -s http://localhost:8080/ create-job 0_TEST
      

      Both environments produced the same error, which I have included below:

       

      Mar 14, 2019 3:26:19 PM hudson.cli.PlainCLIProtocol$EitherSide$Reader run
      WARNING: null
      hudson.cli.DiagnosedStreamCorruptionException
      Read back: 0x00 0x00 0x00 0x0c 0x00 0x00 0x0a
      'create-job' 0x00 0x00 0x00 0x08 0x00 0x00 0x06 '0_TEST' 0x00 0x00 0x00 0x07 0x02 0x00 0x05 'UTF-8' 0x00 0x00 0x00 0x07 0x01 0x00 0x05 'en_GB' 0x00 0x00 0x00 0x00 0x03
      Read ahead:
      Diagnosis problem:
          java.io.IOException: java.util.concurrent.TimeoutException: Idle timeout expired: 5001/5000 ms
              at org.eclipse.jetty.server.HttpInput$ErrorState.noContent(HttpInput.java:1080)
              at org.eclipse.jetty.server.HttpInput.read(HttpInput.java:313)
              at org.eclipse.jetty.server.HttpInput.read(HttpInput.java:256)
              at org.apache.commons.io.input.ProxyInputStream.read(ProxyInputStream.java:59)
              at hudson.cli.FlightRecorderInputStream$1.run(FlightRecorderInputStream.java:59)
          Caused by: java.util.concurrent.TimeoutException: Idle timeout expired: 5001/5000 ms
              at org.eclipse.jetty.io.IdleTimeout.checkIdleTimeout(IdleTimeout.java:166)
              at org.eclipse.jetty.io.IdleTimeout$1.run(IdleTimeout.java:50)
              at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515)
              at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
              at java.base/java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:304)
              at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
              at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
              at java.base/java.lang.Thread.run(Thread.java:834)
              Suppressed: java.lang.Throwable: HttpInput failure
                      at org.eclipse.jetty.server.HttpInput.failed(HttpInput.java:826)
                      at org.eclipse.jetty.server.HttpConnection$BlockingReadCallback.failed(HttpConnection.java:649)
                      at org.eclipse.jetty.io.FillInterest.onFail(FillInterest.java:138)
                      at org.eclipse.jetty.io.AbstractEndPoint.onIdleExpired(AbstractEndPoint.java:406)
                      ... 8 more
              at hudson.cli.FlightRecorderInputStream.analyzeCrash(FlightRecorderInputStream.java:82)
              at hudson.cli.PlainCLIProtocol$EitherSide$Reader.run(PlainCLIProtocol.java:145)
      Caused by: java.io.IOException: java.util.concurrent.TimeoutException: Idle timeout expired: 5001/5000 ms
              at org.eclipse.jetty.server.HttpInput$ErrorState.noContent(HttpInput.java:1080)
              at org.eclipse.jetty.server.HttpInput.read(HttpInput.java:313)
              at org.eclipse.jetty.server.HttpInput.read(HttpInput.java:256)
              at org.apache.commons.io.input.ProxyInputStream.read(ProxyInputStream.java:59)
              at hudson.cli.FlightRecorderInputStream.read(FlightRecorderInputStream.java:88)
              at java.base/java.io.DataInputStream.readInt(DataInputStream.java:392)
              at hudson.cli.PlainCLIProtocol$EitherSide$Reader.run(PlainCLIProtocol.java:110)
      Caused by: java.util.concurrent.TimeoutException: Idle timeout expired: 5001/5000 ms
              at org.eclipse.jetty.io.IdleTimeout.checkIdleTimeout(IdleTimeout.java:166)
              at org.eclipse.jetty.io.IdleTimeout$1.run(IdleTimeout.java:50)
              at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515)
              at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
              at java.base/java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:304)
              at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
              at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
              at java.base/java.lang.Thread.run(Thread.java:834)
              Suppressed: java.lang.Throwable: HttpInput failure
                      at org.eclipse.jetty.server.HttpInput.failed(HttpInput.java:826)
                      at org.eclipse.jetty.server.HttpConnection$BlockingReadCallback.failed(HttpConnection.java:649)
                      at org.eclipse.jetty.io.FillInterest.onFail(FillInterest.java:138)
                      at org.eclipse.jetty.io.AbstractEndPoint.onIdleExpired(AbstractEndPoint.java:406)
                      ... 8 more
      

      We really depend on the application to generate the jobs we on a day-to-day basis, so we would ideally like to see a resolution for this. Otherwise we will need to pursue an alternative method for generating the jobs.

      If any further information is required, please let me know and I will provide it.

       

        Attachments

          Activity

          Hide
          gambo David Abrante added a comment -

          Ended up re-writing the application using the Jenkins REST API instead.

          Has the remote CLI been deprecated? 

          Show
          gambo David Abrante added a comment - Ended up re-writing the application using the Jenkins REST API instead. Has the remote CLI been deprecated? 
          Hide
          jthompson Jeff Thompson added a comment -

          That's a big upgrade to 2.150.2 from 1.454.

          Yes, the Remoting CLI was deprecated over two years ago: https://jenkins.io/blog/2017/04/11/new-cli/

          More recently, as the deprecation had warned, that capability was removed: https://jenkins.io/blog/2019/02/17/remoting-cli-removed/

          I'm glad you were able to find an alternative that works for you.

          I'll close this ticket out.

          Show
          jthompson Jeff Thompson added a comment - That's a big upgrade to 2.150.2 from 1.454. Yes, the Remoting CLI was deprecated over two years ago:  https://jenkins.io/blog/2017/04/11/new-cli/ More recently, as the deprecation had warned, that capability was removed:  https://jenkins.io/blog/2019/02/17/remoting-cli-removed/ I'm glad you were able to find an alternative that works for you. I'll close this ticket out.

            People

            • Assignee:
              jthompson Jeff Thompson
              Reporter:
              gambo David Abrante
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: