Jira displays a blank page when viewing the Notifications page in Project Administration, or throws a NullPointerException when adding a new SMTP mail server
Platform Notice: Data Center Only - This article only applies to Atlassian products on the Data Center platform.
Note that this KB was created for the Data Center version of the product. Data Center KBs for non-Data-Center-specific features may also work for Server versions of the product, however they have not been tested. Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.
*Except Fisheye and Crucible
Summary
Problem
While viewing the Project Administration page for a project, clicking on the Notifications link in the left navigation pane results in a blank page being displayed. In addition, when viewing the Notifications Schemes administration page, the schemes are displayed but no projects are listed as assigned.
The following errors appear in the atlassian-jira.log file when viewing the Notifications page or the Notification schemes administration page.
1
2
3
4
5
6
WARN sysadmin 683x85556x1 nwx0h8 /plugins/servlet/project-config/WP/notifications [c.atlassian.ozymandias.SafePluginPointAccess] Unable to run plugin code because of 'java.lang.NullPointerException - null'.
ERROR sysadmin 683x85697x1 nwx0h8 /secure/admin/ViewNotificationSchemes.jspa [webwork.util.ValueStack] METHOD: "projects", exception:
2015-09-22 11:23:49.796737500 java.lang.NullPointerException
2015-09-22 11:23:49.796738500 at com.atlassian.jira.util.Named$1.compare(Named.java:21)
2015-09-22 11:23:49.796738500 at com.atlassian.jira.util.Named$1.compare(Named.java:18)
Alternatively, the following error might show up in atlassian-jira.log while adding a new Mail Server.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
java.lang.NullPointerException
java.lang.NullPointerException
at com.atlassian.jira.plugins.mail.webwork.AddSmtpMailServer$1.compare(AddSmtpMailServer.java:46)
at com.atlassian.jira.plugins.mail.webwork.AddSmtpMailServer$1.compare(AddSmtpMailServer.java:42)
at java.util.TreeMap.put(TreeMap.java:552)
at java.util.TreeSet.add(TreeSet.java:255)
at java.util.AbstractCollection.addAll(AbstractCollection.java:344)
at java.util.TreeSet.addAll(TreeSet.java:312)
at com.atlassian.jira.plugins.mail.webwork.AddSmtpMailServer.doDefault(AddSmtpMailServer.java:52)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at webwork.util.InjectionUtils$DefaultInjectionImpl.invoke(InjectionUtils.java:70)
at webwork.util.InjectionUtils.invoke(InjectionUtils.java:56)
Note
The blank Notification Scheme page can also be occurring due to another root cause. If the diagnosis steps from this article do not apply to your Jira application, you might want to consider this other KB article instead: Jira displays a blank page or the error java.lang.NullPointerException while accessing the Notifications Tab of Projects
Diagnosis
Run the following SQL statement against the JIRA database to check for the presence of project schemes that lack a project source node association.
1
select * from nodeAssociation where association_type = 'ProjectScheme' and not exists (select 'x' from project where project.id = source_node_id);
If the query above returns results as below, the issue this article describes is present.
1
2
3
4
5
source_node_id | source_node_entity | sink_node_id | sink_node_entity | association_type | sequence
----------------+--------------------+--------------+-----------------------+------------------+----------
15202 | Project | 1 | IssueTypeScreenScheme | ProjectScheme |
15202 | Project | 10000 | NotificationScheme | ProjectScheme |
15202 | Project | 0 | PermissionScheme | ProjectScheme |
Cause
Project database information is corrupt. Could have happened by the incorrect removal of a project caused by an error or broken transaction while calling the method
com.atlassian.jira.project.DefaultProjectManager.removeProject
Solution
Resolution
⚠️ Backup your Jira database before proceeding!
If the SQL select statement produces results, run the following delete statement to remove the invalid entries.
1
delete from nodeAssociation where association_type = 'ProjectScheme' and not exists (select 'x' from project where project.id = source_node_id);
The Notifications page and Notification Schemes page should now display the notifications and project associations as expected.
Was this helpful?