java.lang.NullPointerException

Atlassian JIRA | Jaime Silveira [Atlassian] | 2 years ago
  1. 0

    The summary of some of the issues were becoming ‘null’ when carried out a transition. They were in a Service Desk Project and during the automatic transition ‘Respond to customer’ via comments (automatic transition when a comment is made), the summary became null. This happened with the default workflow created by Service Desk. After investigation, we found out that the problem happened because the ‘Respond to customer’ had associated a screen with the summary. Removing the ‘summary’ field from this screen solves the problem (though it does not fix the issues that have already a null summary). When carrying out the transition, an error is shown to the user. Also, when viewing the issue in the quick view, the same error occurs. Both throw the same NPE with the following stack trace. {noformat} java.lang.NullPointerException at java.security.MessageDigest.update(MessageDigest.java:293) at java.security.MessageDigest.digest(MessageDigest.java:368) at org.apache.commons.codec.digest.DigestUtils.md5(DigestUtils.java:165) at org.apache.commons.codec.digest.DigestUtils.md5(DigestUtils.java:190) at org.apache.commons.codec.digest.DigestUtils.md5Hex(DigestUtils.java:226) at com.atlassian.jira.components.issueeditor.action.DefaultContentIdCollector.calculateContentId(DefaultContentIdCollector.java:59) at com.atlassian.jira.components.issueviewer.viewissue.IssueSummaryProvider.check(IssueSummaryProvider.java:18) at com.atlassian.jira.components.issueviewer.action.AjaxIssueAction.populateIssueFields(AjaxIssueAction.java:166) at com.atlassian.jira.components.issueviewer.action.AjaxIssueAction.doDefault(AjaxIssueAction.java:140) ... {noformat} This is the error: !null_summary_issue_view_error.png! It reads: There was an unexpected error while loading the issue. If you think this message is wrong, please contact your JIRA administrators. *Steps to reproduce* * Have ‘Service Desk’ enabled * Create a Service Desk project (all default) * Go to the project’s only workflow, find the screen for the ‘Respond to Customer’ transition (there is already one) and add the ‘Summary’ field to it * Create an issue in this project * Have two different users, one set as the reporter, the other as the assignee (it does not seem to work if they are the same) * Transition the issue until it is in the ‘Waiting for Support’ status ** Actually, this is probably the first status, so there will be no need to change it, but make sure it indeed is. * Log in as the assignee user * Go to the issue * Make a comment * The transition will be triggered and an error will appear. The issue’s summary will be null *Workaround* * Fixing the screen ** Go to the screen and remove the summary field from it ** Unfortunately, after this it will be impossible to change the summary if you use the ‘Send to Customer’ button (change manually, if needed) * Fixing the bugged issues ** Find the issues that had their summary set as null before correction, by running the SQL: {code:sql} select project.pkey, issuenum, project from jiraissue left join project on jiraissue.project = project.id where summary is null; {code} ** Find the issue key, by joining “<pkey>-<issuenum>” from the SQL ** Open the issue in the UI and give it a summary (it will have ‘null’ written in it). This should do it.

    Atlassian JIRA | 2 years ago | Jaime Silveira [Atlassian]
    java.lang.NullPointerException
  2. 0

    The summary of some of the issues were becoming ‘null’ when carried out a transition. They were in a Service Desk Project and during the automatic transition ‘Respond to customer’ via comments (automatic transition when a comment is made), the summary became null. This happened with the default workflow created by Service Desk. After investigation, we found out that the problem happened because the ‘Respond to customer’ had associated a screen with the summary. Removing the ‘summary’ field from this screen solves the problem (though it does not fix the issues that have already a null summary). When carrying out the transition, an error is shown to the user. Also, when viewing the issue in the quick view, the same error occurs. Both throw the same NPE with the following stack trace. {noformat} java.lang.NullPointerException at java.security.MessageDigest.update(MessageDigest.java:293) at java.security.MessageDigest.digest(MessageDigest.java:368) at org.apache.commons.codec.digest.DigestUtils.md5(DigestUtils.java:165) at org.apache.commons.codec.digest.DigestUtils.md5(DigestUtils.java:190) at org.apache.commons.codec.digest.DigestUtils.md5Hex(DigestUtils.java:226) at com.atlassian.jira.components.issueeditor.action.DefaultContentIdCollector.calculateContentId(DefaultContentIdCollector.java:59) at com.atlassian.jira.components.issueviewer.viewissue.IssueSummaryProvider.check(IssueSummaryProvider.java:18) at com.atlassian.jira.components.issueviewer.action.AjaxIssueAction.populateIssueFields(AjaxIssueAction.java:166) at com.atlassian.jira.components.issueviewer.action.AjaxIssueAction.doDefault(AjaxIssueAction.java:140) ... {noformat} This is the error: !null_summary_issue_view_error.png! It reads: There was an unexpected error while loading the issue. If you think this message is wrong, please contact your JIRA administrators. *Steps to reproduce* * Have ‘Service Desk’ enabled * Create a Service Desk project (all default) * Go to the project’s only workflow, find the screen for the ‘Respond to Customer’ transition (there is already one) and add the ‘Summary’ field to it * Create an issue in this project * Have two different users, one set as the reporter, the other as the assignee (it does not seem to work if they are the same) * Transition the issue until it is in the ‘Waiting for Support’ status ** Actually, this is probably the first status, so there will be no need to change it, but make sure it indeed is. * Log in as the assignee user * Go to the issue * Make a comment * The transition will be triggered and an error will appear. The issue’s summary will be null *Workaround* * Fixing the screen ** Go to the screen and remove the summary field from it ** Unfortunately, after this it will be impossible to change the summary if you use the ‘Send to Customer’ button (change manually, if needed) * Fixing the bugged issues ** Find the issues that had their summary set as null before correction, by running the SQL: {code:sql} select project.pkey, issuenum, project from jiraissue left join project on jiraissue.project = project.id where summary is null; {code} ** Find the issue key, by joining “<pkey>-<issuenum>” from the SQL ** Open the issue in the UI and give it a summary (it will have ‘null’ written in it). This should do it.

    Atlassian JIRA | 2 years ago | Jaime Silveira [Atlassian]
    java.lang.NullPointerException
  3. 0

    PTC Integrity Plugin - Jenkins - Jenkins Wiki

    jenkins-ci.org | 1 year ago
    javax.servlet.ServletException: java.lang.NullPointerException
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    PTC Integrity Plugin - Jenkins - Jenkins Wiki

    jenkins-ci.org | 2 months ago
    java.lang.NullPointerException

  1. linxiaolong 1 times, last 4 months ago
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 java.security.MessageDigest.update()
  2. Java RT
    MessageDigest.digest
    1. java.security.MessageDigest.update(MessageDigest.java:293)
    2. java.security.MessageDigest.digest(MessageDigest.java:368)
    2 frames
  3. Apache Commons Codec
    DigestUtils.md5Hex
    1. org.apache.commons.codec.digest.DigestUtils.md5(DigestUtils.java:165)
    2. org.apache.commons.codec.digest.DigestUtils.md5(DigestUtils.java:190)
    3. org.apache.commons.codec.digest.DigestUtils.md5Hex(DigestUtils.java:226)
    3 frames
  4. com.atlassian.jira
    AjaxIssueAction.doDefault
    1. com.atlassian.jira.components.issueeditor.action.DefaultContentIdCollector.calculateContentId(DefaultContentIdCollector.java:59)
    2. com.atlassian.jira.components.issueviewer.viewissue.IssueSummaryProvider.check(IssueSummaryProvider.java:18)
    3. com.atlassian.jira.components.issueviewer.action.AjaxIssueAction.populateIssueFields(AjaxIssueAction.java:166)
    4. com.atlassian.jira.components.issueviewer.action.AjaxIssueAction.doDefault(AjaxIssueAction.java:140)
    4 frames