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)

book

Article ID: 124973

calendar_today

Updated On:

Products

CLARITY PPM FOR ITG CLARITY PPM FEDERAL Clarity PPM SaaS Clarity PPM On Premise

Issue/Introduction

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)
 
 

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.
 

 
 

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.

Resolution

Workaround #1, 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


If this does not work, WORKAROUND #2  for On Premise:
1. Take a backup of <clarity_install_dir>\lib\osf.object.jar
2. Copy the attached osf.object.jar file to <clarity_install_dir>\lib
 
3. Get the path of the delete_projects_job_S164940.xml
 
It's usually in:
$install\install-packages\15.5.1\package\upgrade\database\schema\xog-seeddata
You may copy it to another location for convenience.
 
4. Run the command after correcting the path to the files:
 
serviceant -f <install_dir>\.setup\scripts\db.xml install-xog-seeddata-file -Dfile=<path of delete_projects_job_S164940.xml> -Dtenant.id=clarity -Dinstall.dir=<install_dir>
 
Example command:
serviceant -f C:\clarity\.setup\scripts\db.xml install-xog-seeddata-file -Dfile=C:\install\install-packages\15.5.1\package\upgrade\database\schema\xog-seeddata\delete_projects_job_S164940.xml -Dtenant.id=clarity -Dinstall.dir=C:\clarity
 
5. Now replace <clarity_install_dir>\lib\osf.object.jar with the original file you backed up in step 1.
6. Re-run the upgrade to 15.5.1.
 

Attachments

1558537020669Workaround1and2.zip get_app