Monday, August 18, 2014

ACM Stakeholder and SCA Organization out of sync

Upon case design for Oracle Adaptive Case Management 12c, included in Oracle Business Process Management 12c, you need to take care that the application role table (organization.xml) of the BPM/ACM service component application and case stakeholder table of the case.

In Oracle BPM Studio 12c, create a new SCA application, e.g. called MyAcmApplication.
Add a BPM project (e.g. MyAcmProject) whose composite contains case management.
Since you selected Composite with Case Management, you will be asked to provide a case name, e.g. MyCase.
Now check for the details of organization.xml of the BPM project from the Applications navigator.
Applications navigator in Oracle BPM Studio 12c

(If the Applications navigator is not already open, in 12c you can find it under Windows menu from the main navigation of BPM Studio. This is different from 11g where it was under View menu.)
Once organization.xml opened, you will notice that so fare, ony the Process Owner and the Process Reviewer application role are present for this project.
Now, go to the Stakeholder property page of the case. Open the case file from the Applications navigator (MyAcmProject > BPM > Case > MyCase). Add a new stakeholder (e.g. MyStakeholder) to the stakeholder list. Don't forget to save.
New stakeholder added to case
Switch back to Organizations tab and notice that the new stakeholder has also been added as BPM application role.
Now, go back to the case definition and delete the prior created stakeholder. Save all. Switch back to the BPM application roles. You will notice that the according application role for your stakeholder did not get deleted aswell. At this point, you are out of sync between you case definitions stakeholders and you BPM applocation roles.

Since BPM application roles are global in the OracleBPMProcessRolesApp, this makes somehow sence to prevent deletion active application roles on redeployment of BPM/ACM applications. On the other hand, deployment won't ever delet application roles from OracleBPMRolesApp. Only updation association of user and groups is possible. Therefore, during design time, this behavior is somehow unexpected.
In the end, it is no big deal since you can still manually delete the application roles. This can be done prior to deployment (so that the application roles doesn't even get propagated to OracleBPMProcessRolesApp) or on runtime using BPM Workspace. It is just something you need to be aware of.