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

SCM polling fails with NPE in EnvInjectPluginAction$1.transformEntry [...] after upgrading to 1.91

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved (View Workflow)
    • Priority: Blocker
    • Resolution: Fixed
    • Component/s: envinject-plugin
    • Labels:
      None
    • Environment:
      Jenkins 1.599 on Windows Server 2008 (x64)
      Subversion Plugin 2.5
      EnvInject Plugin 1.91
    • Similar Issues:

      Description

      After upgrading from Envinject 1.90 to 1.91 the SCM-Polling fails (with following trace):

      Failed to record SCM polling for hudson.model.FreeStyleProject@25640dfb[GMC_NightlyBuild]
      java.lang.NullPointerException
      	at org.jenkinsci.plugins.envinject.EnvInjectPluginAction$1.transformEntry(EnvInjectPluginAction.java:25)
      	at org.jenkinsci.plugins.envinject.EnvInjectPluginAction$1.transformEntry(EnvInjectPluginAction.java:23)
      	at com.google.common.collect.Maps$TransformedEntriesMap$1$1.apply(Maps.java:1218)
      	at com.google.common.collect.Maps$TransformedEntriesMap$1$1.apply(Maps.java:1216)
      	at com.google.common.collect.Iterators$8.next(Iterators.java:812)
      	at java.util.AbstractMap.putAll(AbstractMap.java:280)
      	at java.util.TreeMap.putAll(TreeMap.java:327)
      	at org.jenkinsci.plugins.envinject.EnvInjectVarList.<init>(EnvInjectVarList.java:26)
      	at org.jenkinsci.plugins.envinject.EnvInjectPluginAction.getTarget(EnvInjectPluginAction.java:22)
      	at org.jenkinsci.plugins.envinject.EnvInjectPluginAction.buildEnvVars(EnvInjectPluginAction.java:31)
      	at hudson.model.AbstractBuild.getEnvironment(AbstractBuild.java:929)
      	at hudson.scm.SubversionSCM.compareRemoteRevisionWith(SubversionSCM.java:1343)
      	at hudson.scm.SCM.compareRemoteRevisionWith(SCM.java:380)
      	at hudson.scm.SCM.poll(SCM.java:397)
      	at hudson.model.AbstractProject._poll(AbstractProject.java:1446)
      	at hudson.model.AbstractProject.poll(AbstractProject.java:1349)
      	at hudson.triggers.SCMTrigger$Runner.runPolling(SCMTrigger.java:515)
      	at hudson.triggers.SCMTrigger$Runner.run(SCMTrigger.java:544)
      	at hudson.util.SequentialExecutionQueue$QueueEntry.run(SequentialExecutionQueue.java:118)
      	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:745)
      

      This also occurs for all other jobs (which uses SCM-Polling); a forced job-start (on the other side) runs as expected.

        Attachments

          Issue Links

            Activity

            Hide
            jegr Jens Gross added a comment -

            Same for me with Maven-Projects and git on Jenkins 1.602 and Envinject 1.9.1.
            After downgrade to Envinject 1.9.0 SCM polling works again
            (https://github.com/jenkinsci/envinject-plugin/issues/41)

            Show
            jegr Jens Gross added a comment - Same for me with Maven-Projects and git on Jenkins 1.602 and Envinject 1.9.1. After downgrade to Envinject 1.9.0 SCM polling works again ( https://github.com/jenkinsci/envinject-plugin/issues/41 )
            Show
            oleg_nenashev Oleg Nenashev added a comment - Fixed in https://github.com/jenkinsci/envinject-plugin/commit/07ae2b616a7b7e0bc7fd1e08bfae9865c99d81bb
            Hide
            oleg_nenashev Oleg Nenashev added a comment -

            I've released the version with the patch.
            It should become available soon

            Show
            oleg_nenashev Oleg Nenashev added a comment - I've released the version with the patch. It should become available soon
            Hide
            peteboyrocket Pete W added a comment -

            Also seeing this on our build server:
            Jenkins 1.602 on Windows Server 2012 (x64)
            Subversion Plugin 2.5-beta-2
            EnvInject Plugin 1.91

            Show
            peteboyrocket Pete W added a comment - Also seeing this on our build server: Jenkins 1.602 on Windows Server 2012 (x64) Subversion Plugin 2.5-beta-2 EnvInject Plugin 1.91
            Hide
            dshvedchenko Denis Shvedchenko added a comment -

            after installing 1.91.1 SCM polling works again, thank for reeleasing it quickly

            Show
            dshvedchenko Denis Shvedchenko added a comment - after installing 1.91.1 SCM polling works again, thank for reeleasing it quickly
            Hide
            oleg_nenashev Oleg Nenashev added a comment -

            Thank you too for the auxiliary info and testing.
            I've created JENKINS-27363 to fix the code's self-documentation.

            This issue seems to be resolved

            Show
            oleg_nenashev Oleg Nenashev added a comment - Thank you too for the auxiliary info and testing. I've created JENKINS-27363 to fix the code's self-documentation. This issue seems to be resolved
            Hide
            wolfs Stefan Wolf added a comment -

            Thanks for looking into this.

            Is it necessary to release envinject-lib, too?
            Obviously after merging https://github.com/jenkinsci/envinject-lib/pull/4 and then pulling another release of the envinject-plugin?

            Show
            wolfs Stefan Wolf added a comment - Thanks for looking into this. Is it necessary to release envinject-lib, too? Obviously after merging https://github.com/jenkinsci/envinject-lib/pull/4 and then pulling another release of the envinject-plugin?
            Hide
            oleg_nenashev Oleg Nenashev added a comment -

            Stefan Wolf,IMO there's no urgent need to release additional versions of envinject-lib & envinject-plugin.

            The bug on user side (this issue) has been solved in 1.91.1. All other changes are mostly related to the code quality, so we can release these changes together with future functional patches

            Show
            oleg_nenashev Oleg Nenashev added a comment - Stefan Wolf ,IMO there's no urgent need to release additional versions of envinject-lib & envinject-plugin. The bug on user side (this issue) has been solved in 1.91.1. All other changes are mostly related to the code quality, so we can release these changes together with future functional patches

              People

              • Assignee:
                gbois Gregory Boissinot
                Reporter:
                ibiatiroler Markus Eisenmann
              • Votes:
                2 Vote for this issue
                Watchers:
                7 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: