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

S3 artifact download fails due to null selector

    XMLWordPrintable

Details

    Description

      Started by user anonymous
      Building in workspace /home/directhex/Projects/s3-plugin/work/workspace/downloader-test
      
      Deleting project workspace... done
      
      ERROR: Build step failed with exception
      java.lang.NullPointerException
      	at hudson.plugins.s3.S3CopyArtifact.perform(S3CopyArtifact.java:169)
      	at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:20)
      	at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:779)
      	at hudson.model.Build$BuildExecution.build(Build.java:205)
      	at hudson.model.Build$BuildExecution.doRun(Build.java:162)
      	at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:537)
      	at hudson.model.Run.execute(Run.java:1741)
      	at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
      	at hudson.model.ResourceController.execute(ResourceController.java:98)
      	at hudson.model.Executor.run(Executor.java:381)
      Build step 'S3 Copy Artifact' marked build as failure
      Finished: FAILURE
      

      Attachments

        Issue Links

          Activity

            directhex Jo Shields added a comment - Okay, https://github.com/directhex/s3-plugin/commit/11b22c150957cf6f4ff435b1461f6c80d1b2237d seems to cover all bases for me.
            rafael_vend Rafael Fonseca added a comment - - edited

            We're seeing the same errors appear in our logs for multiple jobs, and we traced it to the plugin dropping the selector part of the XML config whenever we save the job configuration.

            Before saving:

                <hudson.plugins.s3.S3CopyArtifact plugin="s3@0.7">
                  <projectName>reporting-build</projectName>
                  <filter>**/*</filter>
                  <target></target>
                  <selector class="hudson.plugins.copyartifact.ParameterizedBuildSelector" plugin="copyartifact@1.35.2">
                    <parameterName>ARTIFACT_BUILD_ID</parameterName>
                  </selector>
                </hudson.plugins.s3.S3CopyArtifact>
            

            After saving the job config:

                <hudson.plugins.s3.S3CopyArtifact plugin="s3@0.7">
                  <projectName>reporting-build</projectName>
                  <filter>**/*</filter>
                  <target></target>
                </hudson.plugins.s3.S3CopyArtifact>
            

            We are not, however, using the workspace cleanup plugin in our build process.

            rafael_vend Rafael Fonseca added a comment - - edited We're seeing the same errors appear in our logs for multiple jobs, and we traced it to the plugin dropping the selector part of the XML config whenever we save the job configuration. Before saving: <hudson.plugins.s3.S3CopyArtifact plugin= "s3@0.7" > <projectName> reporting-build </projectName> <filter> **/* </filter> <target> </target> <selector class= "hudson.plugins.copyartifact.ParameterizedBuildSelector" plugin= "copyartifact@1.35.2" > <parameterName> ARTIFACT_BUILD_ID </parameterName> </selector> </hudson.plugins.s3.S3CopyArtifact> After saving the job config: <hudson.plugins.s3.S3CopyArtifact plugin= "s3@0.7" > <projectName> reporting-build </projectName> <filter> **/* </filter> <target> </target> </hudson.plugins.s3.S3CopyArtifact> We are not, however, using the workspace cleanup plugin in our build process.
            ringerc Craig Ringer added a comment - - edited

            Same here - no workspace cleanup plugin, same failure. In my case it's not even necessary to save the job configuration. Existing jobs stopped working when I upgraded Jenkins to 1.637.

            Possibly unrelated.

            ringerc Craig Ringer added a comment - - edited Same here - no workspace cleanup plugin, same failure. In my case it's not even necessary to save the job configuration. Existing jobs stopped working when I upgraded Jenkins to 1.637. Possibly unrelated.
            directhex Jo Shields added a comment - It's fixed in https://github.com/jenkinsci/s3-plugin/pull/63 FWIW.
            jimilian Alexander A added a comment -

            directhex Could you check in last version (0.9.1)?

            jimilian Alexander A added a comment - directhex Could you check in last version (0.9.1)?

            People

              jimilian Alexander A
              directhex Jo Shields
              Votes:
              3 Vote for this issue
              Watchers:
              6 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: