java.lang.NullPointerException

There are no available Samebug tips for this exception. Do you have an idea how to solve this issue? A short tip would help users who saw this issue last week.

  • When we use this plugin in the pipeline, we got a NullPointerException, we want to use credentials (created in the same folder as the pipeline project so other people can't use), as shown below. We are using Jenkins 2.7.1. stage 'Promote' nexusArtifactUploader artifactId: a, credentialsId: '03061789-shortened-1ed6f456', file: a + '.zip', groupId: g, nexusPassword: '', nexusUrl: 'invnexus.mycompany.com/nexus', nexusUser: '', packaging: 'zip', protocol: 'http', repository: 'otpp-releases', version: new_version D:\public\workspace\Release\Promote@2>Powershell -Command "Add-Type -Assembly System.IO.Compression.FileSystem; System.IO.Compression.ZipFile::CreateFromDirectory(\"stage\", \"pmer.zip\", System.IO.Compression.CompressionLevel::Optimal, $false)" Pipeline nexusArtifactUploader Pipeline } Pipeline // ws Pipeline } Pipeline // node Pipeline End of Pipeline java.lang.NullPointerException at sp.sd.nexusartifactuploader.steps.NexusArtifactUploaderStep.getUsername(NexusArtifactUploaderStep.java:153) at sp.sd.nexusartifactuploader.steps.NexusArtifactUploaderStep$Execution.run(NexusArtifactUploaderStep.java:276) at sp.sd.nexusartifactuploader.steps.NexusArtifactUploaderStep$Execution.run(NexusArtifactUploaderStep.java:250) at org.jenkinsci.plugins.workflow.steps.AbstractSynchronousNonBlockingStepExecution$1$1.call(AbstractSynchronousNonBlockingStepExecution.java:52) at hudson.security.ACL.impersonate(ACL.java:213) at org.jenkinsci.plugins.workflow.steps.AbstractSynchronousNonBlockingStepExecution$1.run(AbstractSynchronousNonBlockingStepExecution.java:49) 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.runWorker(Unknown Source) at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) at java.lang.Thread.run(Unknown Source) Finished: FAILURE Reported by [~hujirong]
    via by Suresh Kumar,
  • When we use this plugin in the pipeline, we got a NullPointerException, we want to use credentials (created in the same folder as the pipeline project so other people can't use), as shown below. We are using Jenkins 2.7.1. stage 'Promote' nexusArtifactUploader artifactId: a, credentialsId: '03061789-shortened-1ed6f456', file: a + '.zip', groupId: g, nexusPassword: '', nexusUrl: 'invnexus.mycompany.com/nexus', nexusUser: '', packaging: 'zip', protocol: 'http', repository: 'otpp-releases', version: new_version D:\public\workspace\Release\Promote@2>Powershell -Command "Add-Type -Assembly System.IO.Compression.FileSystem; System.IO.Compression.ZipFile::CreateFromDirectory(\"stage\", \"pmer.zip\", System.IO.Compression.CompressionLevel::Optimal, $false)" Pipeline nexusArtifactUploader Pipeline } Pipeline // ws Pipeline } Pipeline // node Pipeline End of Pipeline java.lang.NullPointerException at sp.sd.nexusartifactuploader.steps.NexusArtifactUploaderStep.getUsername(NexusArtifactUploaderStep.java:153) at sp.sd.nexusartifactuploader.steps.NexusArtifactUploaderStep$Execution.run(NexusArtifactUploaderStep.java:276) at sp.sd.nexusartifactuploader.steps.NexusArtifactUploaderStep$Execution.run(NexusArtifactUploaderStep.java:250) at org.jenkinsci.plugins.workflow.steps.AbstractSynchronousNonBlockingStepExecution$1$1.call(AbstractSynchronousNonBlockingStepExecution.java:52) at hudson.security.ACL.impersonate(ACL.java:213) at org.jenkinsci.plugins.workflow.steps.AbstractSynchronousNonBlockingStepExecution$1.run(AbstractSynchronousNonBlockingStepExecution.java:49) 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.runWorker(Unknown Source) at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) at java.lang.Thread.run(Unknown Source) Finished: FAILURE
    via by Jirong Hu,
  • [JIRA] (JENKINS-41619) NPE in Pipeline Step after update
    via by in...@andreas-steffens.de (JIRA),
    • java.lang.NullPointerException at sp.sd.nexusartifactuploader.steps.NexusArtifactUploaderStep.getUsername(NexusArtifactUploaderStep.java:153) at sp.sd.nexusartifactuploader.steps.NexusArtifactUploaderStep$Execution.run(NexusArtifactUploaderStep.java:276) at sp.sd.nexusartifactuploader.steps.NexusArtifactUploaderStep$Execution.run(NexusArtifactUploaderStep.java:250) at org.jenkinsci.plugins.workflow.steps.AbstractSynchronousNonBlockingStepExecution$1$1.call(AbstractSynchronousNonBlockingStepExecution.java:52) at hudson.security.ACL.impersonate(ACL.java:213) at org.jenkinsci.plugins.workflow.steps.AbstractSynchronousNonBlockingStepExecution$1.run(AbstractSynchronousNonBlockingStepExecution.java:49) 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.runWorker(Unknown Source) at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) at java.lang.Thread.run(Unknown Source)
    No Bugmate found.