7.1.2, 7.2.7, 7.2.8
Performing a JIRA restore from an xml backup is failing with java.lang.NullPointerException when there is a long string in the field : 'oldstring' for 'changeitem' table.
JIRA does not provide any helpful logging here to help determine why the restore failed. We need to have better logging for this failure.
Steps to Reproduce
- Restore a backup of JIRA from Administration > System > Restore System
Restore finishes successfully
Restore fails but without giving any reason why it failed
The below exception is thrown in the atlassian-jira.log file:
2017-04-05 17:34:16,441 http-nio-8351-exec-17 ERROR [o.a.c.c.C.[.[localhost].[/JSP-283501].[default]] Servlet.service() for servlet [default] in context with path [/JSP-xxxx] threw exception java.lang.NullPointerException at com.atlassian.jira.web.filters.JiraImportProgressFilter.doFilter(JiraImportProgressFilter.java:130) at com.atlassian.core.filters.AbstractHttpFilter.doFilter(AbstractHttpFilter.java:31) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:239) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:219) ... 11 filtered at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) at java.lang.Thread.run(Thread.java:745)
- Enable TRACE logging on the class 'com.atlassian.jira.bc.dataimport' and 'com.atlassian.jira.imports'
- Now start the restore
- When the restore fails, look through the atlassian-jira.log file to determine which record it was reading from entities.xml
- Open the entities.xml file to see that row. That should help to find where the restore is failing.
The issue was mitigated in versions 7.3.7 and 7.4.0. Jira will now report any unexpected failure during data import
that is from 20% to 90% of import progress. Problems that happen outside of this range can still be not printed in log. Example: out of memory during XML parsing.
- mentioned in