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

Maven version detection fails on same agent with 'java.lang.IllegalStateException: zip file closed' exception

    Details

    • Type: Bug
    • Status: Resolved (View Workflow)
    • Priority: Blocker
    • Resolution: Fixed
    • Component/s: maven-plugin
    • Labels:
    • Environment:
    • Similar Issues:

      Description

      Have setup 4 jenkins jobs to run on the same node, and a job that triggers all 4 jobs at the same time

      job-parent -> maven-job1
      maven-job2
      maven-job3
      maven-job4

      When Running job-parent almost every time 2-3 jobs out of 4 fail at checking out the code with the following exception:
       

      Started by upstream project "SanityLinux-UBUNTU14.04-D1-EXT4" build number 4
      originally caused by:
       Started by user Administrator
      Building remotely on Sanity-Pool01-AutoSlaveLinux (windows) in workspace c:\jenkins\workspace\SanityLinux-UBUNTU14.04-D1-EXT4-D2-LVM-EXT4
      Fetching changes from the remote Git repository
      Checking out Revision 01b711db99104fcdd4a0946ac1ad5e5ee8d248dc (origin/7.25)
      ERROR: Processing failed due to a bug in the code. Please report this to jenkinsci-users@googlegroups.com
      java.lang.IllegalStateException: zip file closed
      	at java.util.zip.ZipFile.ensureOpen(Unknown Source)
      	at java.util.zip.ZipFile.getEntry(Unknown Source)
      	at java.util.jar.JarFile.getEntry(Unknown Source)
      	at sun.net.www.protocol.jar.URLJarFile.getEntry(Unknown Source)
      	at sun.net.www.protocol.jar.JarURLConnection.connect(Unknown Source)
      	at sun.net.www.protocol.jar.JarURLConnection.getJarFile(Unknown Source)
      	at hudson.maven.MavenEmbedderUtils.getMavenVersion(MavenEmbedderUtils.java:212)
      	at hudson.maven.MavenVersionCallable.call(MavenVersionCallable.java:69)
      	at hudson.maven.MavenVersionCallable.call(MavenVersionCallable.java:41)
      	at hudson.remoting.UserRequest.perform(UserRequest.java:153)
      	at hudson.remoting.UserRequest.perform(UserRequest.java:50)
      	at hudson.remoting.Request$2.run(Request.java:336)
      	at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:68)
      	at java.util.concurrent.FutureTask.run(Unknown Source)
      	at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
      	at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
      	at hudson.remoting.Engine$1$1.run(Engine.java:94)
      	at java.lang.Thread.run(Unknown Source)
      	at ......remote call to Channel to /10.11.6.120(Native Method)
      	at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1537)
      	at hudson.remoting.UserResponse.retrieve(UserRequest.java:253)
      	at hudson.remoting.Channel.call(Channel.java:822)
      	at hudson.FilePath.act(FilePath.java:1080)
      	at hudson.maven.MavenModuleSetBuild$MavenModuleSetBuildExecution.doRun(MavenModuleSetBuild.java:642)
      	at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:534)
      	at hudson.model.Run.execute(Run.java:1728)
      	at hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:544)
      	at hudson.model.ResourceController.execute(ResourceController.java:98)
      	at hudson.model.Executor.run(Executor.java:404)
      project=hudson.maven.MavenModuleSet@44df909[SanityLinux-UBUNTU14.04-D1-EXT4-D2-LVM-EXT4]
      project.getModules()=[hudson.maven.MavenModule@197eae6e[SanityLinux-UBUNTU14.04-D1-EXT4-D2-LVM-EXT4/com.winmagic.qa:automation-tests][SanityLinux-UBUNTU14.04-D1-EXT4-D2-LVM-EXT4/com.winmagic.qa:automation-tests][relativePath:]]
      project.getRootModule()=hudson.maven.MavenModule@197eae6e[SanityLinux-UBUNTU14.04-D1-EXT4-D2-LVM-EXT4/com.winmagic.qa:automation-tests][SanityLinux-UBUNTU14.04-D1-EXT4-D2-LVM-EXT4/com.winmagic.qa:automation-tests][relativePath:]
      FATAL: zip file closed
      java.lang.IllegalStateException: zip file closed
      	at java.util.zip.ZipFile.ensureOpen(Unknown Source)
      	at java.util.zip.ZipFile.getEntry(Unknown Source)
      	at java.util.jar.JarFile.getEntry(Unknown Source)
      	at sun.net.www.protocol.jar.URLJarFile.getEntry(Unknown Source)
      	at sun.net.www.protocol.jar.JarURLConnection.connect(Unknown Source)
      	at sun.net.www.protocol.jar.JarURLConnection.getJarFile(Unknown Source)
      	at hudson.maven.MavenEmbedderUtils.getMavenVersion(MavenEmbedderUtils.java:212)
      	at hudson.maven.MavenVersionCallable.call(MavenVersionCallable.java:69)
      	at hudson.maven.MavenVersionCallable.call(MavenVersionCallable.java:41)
      	at hudson.remoting.UserRequest.perform(UserRequest.java:153)
      	at hudson.remoting.UserRequest.perform(UserRequest.java:50)
      	at hudson.remoting.Request$2.run(Request.java:336)
      	at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:68)
      	at java.util.concurrent.FutureTask.run(Unknown Source)
      	at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
      	at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
      	at hudson.remoting.Engine$1$1.run(Engine.java:94)
      	at java.lang.Thread.run(Unknown Source)
      	at ......remote call to Channel to /10.11.6.120(Native Method)
      	at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1537)
      	at hudson.remoting.UserResponse.retrieve(UserRequest.java:253)
      	at hudson.remoting.Channel.call(Channel.java:822)
      	at hudson.FilePath.act(FilePath.java:1080)
      	at hudson.maven.MavenModuleSetBuild$MavenModuleSetBuildExecution.doRun(MavenModuleSetBuild.java:642)
      	at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:534)
      	at hudson.model.Run.execute(Run.java:1728)
      	at hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:544)
      	at hudson.model.ResourceController.execute(ResourceController.java:98)
      	at hudson.model.Executor.run(Executor.java:404)
      Finished: FAILURE
      

        Attachments

          Issue Links

            Activity

            Hide
            aheritier Arnaud Héritier added a comment -

            Will be fixed in 3.0-rc2

            Show
            aheritier Arnaud Héritier added a comment - Will be fixed in 3.0-rc2
            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: Arnaud Heritier
            Path:
            pom.xml
            http://jenkins-ci.org/commit/maven-plugin/a267e66db9aa062251f3ee493cf2431c2c0a1f6d
            Log:
            Merge pull request #104 from oleg-nenashev/JENKINS-47233

            JENKINS-47233 - Restore the fix of JENKINS-42549

            Compare: https://github.com/jenkinsci/maven-plugin/compare/298861e13211...a267e66db9aa

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Arnaud Heritier Path: pom.xml http://jenkins-ci.org/commit/maven-plugin/a267e66db9aa062251f3ee493cf2431c2c0a1f6d Log: Merge pull request #104 from oleg-nenashev/ JENKINS-47233 JENKINS-47233 - Restore the fix of JENKINS-42549 Compare: https://github.com/jenkinsci/maven-plugin/compare/298861e13211...a267e66db9aa
            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: Oleg Nenashev
            Path:
            pom.xml
            http://jenkins-ci.org/commit/maven-plugin/8893af0751e819c09e6184103bdf24285747fd7a
            Log:
            JENKINS-47233 - Restore the fix of JENKINS-42549

            The fix has been reverted in 3.0.0-rc1 by https://github.com/jenkinsci/maven-plugin/pull/102.
            It was just a mistake I made when patching the dependencies, but unfortunately nobody noticed it during the code review.

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Oleg Nenashev Path: pom.xml http://jenkins-ci.org/commit/maven-plugin/8893af0751e819c09e6184103bdf24285747fd7a Log: JENKINS-47233 - Restore the fix of JENKINS-42549 The fix has been reverted in 3.0.0-rc1 by https://github.com/jenkinsci/maven-plugin/pull/102 . It was just a mistake I made when patching the dependencies, but unfortunately nobody noticed it during the code review.
            Hide
            oleg_nenashev Oleg Nenashev added a comment -
            Show
            oleg_nenashev Oleg Nenashev added a comment - https://github.com/jenkinsci/maven-plugin/pull/104 is in the review
            Hide
            oleg_nenashev Oleg Nenashev added a comment -

            It is my mistake. In https://github.com/jenkinsci/maven-plugin/pull/102/ I was playing with the dependencies and unintentionally reverted the patch I applied to lib-jenkins-maven-embedder

            Show
            oleg_nenashev Oleg Nenashev added a comment - It is my mistake. In https://github.com/jenkinsci/maven-plugin/pull/102/ I was playing with the dependencies and unintentionally reverted the patch I applied to lib-jenkins-maven-embedder
            Hide
            aheritier Arnaud Héritier added a comment -

            This problem is back with maven-plugin 3.0-rc1

            Reported by Mykola Lynnyk in the original case JENKINS-42549 and confirm it is a regression (2.17 was fixing it)

            Show
            aheritier Arnaud Héritier added a comment - This problem is back with maven-plugin 3.0-rc1 Reported by Mykola Lynnyk in the original case JENKINS-42549 and confirm it is a regression (2.17 was fixing it)

              People

              • Assignee:
                oleg_nenashev Oleg Nenashev
                Reporter:
                andrei_caragheorghii Andrei Caragheorghii
              • Votes:
                2 Vote for this issue
                Watchers:
                6 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: