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

NullPointerException when calling addRecipients

    XMLWordPrintable

    Details

    • Similar Issues:

      Description

      I think the issue is similar to

      https://issues.jenkins-ci.org/browse/JENKINS-29249

       

      I got error log. The issue is seldom. It should be happen after run a long time :

      15:06:41 Notifying upstream projects of job completion*15:06:41* Email was triggered for: Always*15:06:41* Sending email for trigger: Always*15:06:41* ERROR: Could not send email as a part of the post-build publishers.15:06:41 java.lang.NullPointerException15:06:41       at hudson.plugins.emailext.plugins.recipients.RequesterRecipientProvider.addRecipients(RequesterRecipientProvider.java:56)15:06:41       at hudson.plugins.emailext.ExtendedEmailPublisher.createMail(ExtendedEmailPublisher.java:637)15:06:41       at hudson.plugins.emailext.ExtendedEmailPublisher.sendMail(ExtendedEmailPublisher.java:355)15:06:41       at hudson.plugins.emailext.ExtendedEmailPublisher._perform(ExtendedEmailPublisher.java:345)15:06:41       at hudson.plugins.emailext.ExtendedEmailPublisher.perform(ExtendedEmailPublisher.java:253)15:06:41       at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:20)15:06:41       at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:779)15:06:41       at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:720)15:06:41       at hudson.model.Build$BuildExecution.cleanUp(Build.java:195)15:06:41       at hudson.model.Run.execute(Run.java:1775)15:06:41       at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)15:06:41       at hudson.model.ResourceController.execute(ResourceController.java:98)15:06:41       at hudson.model.Executor.run(Executor.java:404)

       

      It is a daily build job.

      The job contains several trigger jobs.

      And 3 Post-build Actions:

      1. log parser
      2. send mail
      3. trigger daily_build_monitor

      It is a recursive trigger. Objectivity is for monitor daily build generate.

      14:02:36 Started by upstream project "daily_build_monitor" build number 579
      14:02:36 originally caused by:
      14:02:36 Started by upstream project "daily_build_monitor" build number 578
      14:02:36 originally caused by:
      14:02:36 Started by upstream project "daily_build_monitor" build number 577
      14:02:36 originally caused by:
      14:02:36 Started by upstream project "daily_build_monitor" build number 576
      14:02:36 originally caused by:
      14:02:36 Started by upstream project "daily_build_monitor" build number 575
      14:02:36 originally caused by:
      14:02:36 Started by upstream project "daily_build_monitor" build number 574
      14:02:36 originally caused by:
      14:02:36 Started by upstream project "daily_build_monitor" build number 573
      14:02:36 originally caused by:
      14:02:36 Started by upstream project "daily_build_monitor" build number 572
      14:02:36 originally caused by:
      14:02:36 Started by upstream project "daily_build_monitor" build number 571
      14:02:36 originally caused by:
      14:02:36 Started by upstream project "daily_build_monitor" build number 570
      14:02:36 originally caused by:
      14:02:36 Started by upstream project "daily_build_monitor" build number 569
      14:02:36 originally caused by:
      14:02:36 Started by upstream project "daily_build_monitor" build number 568
      14:02:36 originally caused by:
      14:02:36 (deeply nested causes)

       

      And this issue similar following link for you to refer

      https://issues.jenkins-ci.org/browse/JENKINS-23269

      Suggestion:
      either return on "build == null"
      or check Run upstream = job.getBuildByNumber(upstreamCause.getUpstreamBuild()); for null too

        Attachments

          Activity

          Show
          davidvanlaatum David van Laatum added a comment - Added a null check https://repo.jenkins-ci.org/snapshots/org/jenkins-ci/plugins/email-ext/2.59-SNAPSHOT/email-ext-2.59-20170715.030138-1.hpi  is a snapshot build that should be good.
          Hide
          rockyeh Rock Yeh added a comment -

          Thanks for response quickly.

          Does the modification will merge to release branch?

           

          Thanks

          Show
          rockyeh Rock Yeh added a comment - Thanks for response quickly. Does the modification will merge to release branch?   Thanks
          Hide
          davidvanlaatum David van Laatum added a comment -

          It will be in the next release but you can install the snapshot build until then

          Show
          davidvanlaatum David van Laatum added a comment - It will be in the next release but you can install the snapshot build until then
          Hide
          davidvanlaatum David van Laatum added a comment - - edited

          Releasing 2.59

          Show
          davidvanlaatum David van Laatum added a comment - - edited Releasing 2.59
          Hide
          ssbarnea Sorin Sbarnea added a comment -

          David van Laatum can you please release 2.60 because 2.59 contains only the fix for HTML? The patch for PLAIN text came two days later.

          Show
          ssbarnea Sorin Sbarnea added a comment - David van Laatum can you please release 2.60 because 2.59 contains only the fix for HTML? The patch for PLAIN text came two days later.
          Hide
          davidvanlaatum David van Laatum added a comment -

          Released 2.60

          Show
          davidvanlaatum David van Laatum added a comment - Released 2.60

            People

            • Assignee:
              davidvanlaatum David van Laatum
              Reporter:
              rockyeh Rock Yeh
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: