java.lang.NullPointerException

Jenkins JIRA | Rainer Burgstaller | 5 years ago
tip
Click on the to mark the solution that helps you, Samebug will learn from it.
As a community member, you’ll be rewarded for you help.
  1. 0

    I have a matrix based security setup where "authenticated" can do everything and anonymous can do nothing. In addition, I am using the template-project-plugin. In such a configuration polling the SCM will fail due to Hudson.getItem() returning {{null}}. The reason for that is that the authentication of the {{SCMTrigger.run}} method is null and therefore, jenkins assumes that this user is unauthenticated (anonymous) and therefore, does not have any permissions whatsoever. {noformat} ERROR: Failed to record SCM polling for java.lang.NullPointerException: project is null, at hudson.plugins.templateproject.ProxySCM.requiresWorkspaceForPolling(ProxySCM.java:179) at hudson.model.AbstractProject._poll(AbstractProject.java:1417) at hudson.model.AbstractProject.poll(AbstractProject.java:1387) at hudson.triggers.SCMTrigger$Runner.runPolling(SCMTrigger.java:420) at hudson.triggers.SCMTrigger$Runner.run(SCMTrigger.java:449) at hudson.util.SequentialExecutionQueue$QueueEntry.run(SequentialExecutionQueue.java:118) at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source) at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source) at java.util.concurrent.FutureTask.run(Unknown Source) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source) at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) at java.lang.Thread.run(Unknown Source) {noformat} Whether this is a bug in ProxySCM (and therefore the template plugin) or whether this is a general problem is hard for me to tell. I was able to work around the problem by giving "Job/read" permission to "anonymous" but IMHO the SCMTrigger should run as SYSTEM.

    Jenkins JIRA | 4 years ago | Rainer Burgstaller
    java.lang.NullPointerException: project is null,
  2. Speed up your debug routine!

    Automated exception search integrated into your IDE

  3. 0

    I have a matrix based security setup where "authenticated" can do everything and anonymous can do nothing. In addition, I am using the template-project-plugin. In such a configuration polling the SCM will fail due to Hudson.getItem() returning {{null}}. The reason for that is that the authentication of the {{SCMTrigger.run}} method is null and therefore, jenkins assumes that this user is unauthenticated (anonymous) and therefore, does not have any permissions whatsoever. {noformat} ERROR: Failed to record SCM polling for java.lang.NullPointerException: project is null, at hudson.plugins.templateproject.ProxySCM.requiresWorkspaceForPolling(ProxySCM.java:179) at hudson.model.AbstractProject._poll(AbstractProject.java:1417) at hudson.model.AbstractProject.poll(AbstractProject.java:1387) at hudson.triggers.SCMTrigger$Runner.runPolling(SCMTrigger.java:420) at hudson.triggers.SCMTrigger$Runner.run(SCMTrigger.java:449) at hudson.util.SequentialExecutionQueue$QueueEntry.run(SequentialExecutionQueue.java:118) at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source) at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source) at java.util.concurrent.FutureTask.run(Unknown Source) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source) at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) at java.lang.Thread.run(Unknown Source) {noformat} Whether this is a bug in ProxySCM (and therefore the template plugin) or whether this is a general problem is hard for me to tell. I was able to work around the problem by giving "Job/read" permission to "anonymous" but IMHO the SCMTrigger should run as SYSTEM.

    Jenkins JIRA | 4 years ago | Rainer Burgstaller
    java.lang.NullPointerException: project is null,
  4. 0

    Getting a nullpointer exception when switching displayables in J2ME

    Stack Overflow | 6 years ago | Pallinder
    java.lang.NullPointerException: 0 at javax.microedition.lcdui.Display$ChameleonTunnel.callScreenListener(), bci=46 at com.sun.midp.chameleon.layers.SoftButtonLayer.processCommand(), bci=74 at com.sun.midp.chameleon.layers.SoftButtonLayer.soft1(), bci=37 at com.sun.midp.chameleon.layers.SoftButtonLayer.keyInput(), bci=36 at com.sun.midp.chameleon.CWindow.keyInput(), bci=38 at javax.microedition.lcdui.Display$DisplayEventConsumerImpl.handleKeyEvent(), bci=17 at com.sun.midp.lcdui.DisplayEventListener.process(), bci=277 at com.sun.midp.events.EventQueue.run(), bci=179

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. java.lang.NullPointerException

      No message provided

      at hudson.plugins.templateproject.ProxySCM.requiresWorkspaceForPolling()
    2. hudson.plugins.templateproject
      ProxySCM.requiresWorkspaceForPolling
      1. hudson.plugins.templateproject.ProxySCM.requiresWorkspaceForPolling(ProxySCM.java:124)
      1 frame
    3. Hudson
      SequentialExecutionQueue$QueueEntry.run
      1. hudson.model.AbstractProject._poll(AbstractProject.java:1365)
      2. hudson.model.AbstractProject.poll(AbstractProject.java:1335)
      3. hudson.triggers.SCMTrigger$Runner.runPolling(SCMTrigger.java:420)
      4. hudson.triggers.SCMTrigger$Runner.run(SCMTrigger.java:449)
      5. hudson.util.SequentialExecutionQueue$QueueEntry.run(SequentialExecutionQueue.java:118)
      5 frames
    4. Java RT
      Thread.run
      1. java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
      2. java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source)
      3. java.util.concurrent.FutureTask.run(Unknown Source)
      4. java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source)
      5. java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
      6. java.lang.Thread.run(Unknown Source)
      6 frames