PPM Upgrade fails with Failure occurred while applying delete_projects_job_S164940.xml, java.lang.NullPointerException at com.niku.odf.ori.xblhandlers.EntityHandler.modifyBusinessObject(EntityHandler.java:185)

Document ID : KB000124973
Last Modified Date : 10/04/2019
Show Technical Document Details
Issue:
Upgrade to 15.5.1 fails with error:
During upgrade from 15.5 to 15.5.1
1/07/19 11:55 AM (ExecTask) Error Applying XOG: Failure occurred while applying delete_projects_job_S164940.xml
1/07/19 11:55 AM (ExecTask) Check D:\niku\clarity/logs/xog-seeddata/out/database\delete_projects_job_S164940_out.xml for errors
1/07/19 11:55 AM (ExecTask) ERROR: Upgrade failed for tenant
 
Error in delete_projects_job_S164940_out.xml file:
XOG-3300: Job Definition record has not been inserted java.lang.NullPointerException
at com.niku.odf.ori.xblhandlers.EntityHandler.modifyBusinessObject(EntityHandler.java:185)
at com.niku.odf.ori.xblhandlers.EntityHandler.processOdfRequest(EntityHandler.java:120)
at com.niku.odf.ori.xblhandlers.EntityHandler.postProcess(EntityHandler.java:57)
at com.niku.xql2.XQLVisitor.postProcess(XQLVisitor.java:1416)
at com.niku.union.xml.dom.DOMWalker.postProcess(DOMWalker.java:210)
 
 
Environment:
Upgrade to 15.5.1
This may occur on other PPM versions, when xogging in a job definition with same root cause and fix.
Cause:
This is caused by DE46559
 If a job is applied with new parameter(s) which had no parameters before.

delete_projects_job_S164940.xml is a change for a new feature, the Delete Investments job will have an additional parameter:
New Parameter in the Delete Investments Job
  1. 'Delete Marked Investments with Timesheet and Transaction Data'
  2. By Default the option is false / unchecked
 
The defect is in how the application determines about the new parameters being inserted. It's data dependent so will not occur on all environments.
 

 
 
Resolution:
Workaround, after rollback:
1. Copy the attached PREPARE_DEL_PROJ_FOR_UPGRADE.xml file to the server
2. Navigate to $clarity\bin and run the command, providing the correct path to the file (or you can also place it in $clarity\bin and not provide the full path):
dbpatch -install -file $temp\PREPARE_DEL_PROJ_FOR_UPGRADE.xml -apply
3. Once it's successful, re-run the upgrade
 
File Attachments:
PREPARE_DEL_PROJ_FOR_UPGRADE.xml