List all BPM Processes for a user
Posted
by kasriniv
on Oracle Blogs
See other posts from Oracle Blogs
or by kasriniv
Published on Thu, 12 Apr 2012 10:46:14 -0500
Indexed on
2012/04/12
17:36 UTC
Read the original article
Hit count: 246
/BPMN
Hello,
Happy to start contributing to this blog..
The title of the blog is probably deceptively simple and warrants an elaboration.
Customized BPM workspaces/user interfaces are a fairly common requirement. One of our marquee customers in the online stock trading business, envisioned this user interaction for their BPM application:
- User logs in to the internal portal
- Use will have list of roles which he is granted as a drop down list
- Once user selects the role, a list of processes which user is part of appear. Logged in user can be part of any swimlane role of the process
- Intialize workflow/BPM context as usual
- Get a handle on InstanceQueryService(getInstanceQueryService), InstanceManagementService, ProcessMetadataService and ProcessModelService
- List all Processes for that bpmcontext (listProcessMetadataSumary) and get Granted roles to that user
- For each of the processes [method getAccessibleProcesss(ProcessMetadataSummary, Set)]for each of the lanes in the process, check if the role granted to the user, matches the roleName for that swimlane. If so, add to output.
Notes:
- The usual caveats apply including BPM APIs are subject to change.
- JDeveloper method introspection is your better friend than API documentation :-)...
(I am going to try upload the source code and if it doesnt work, will follow this blog up with the corresponding source code.)
Hope this helps.
Ack: Yogesh K, BPM Dev team.
© Oracle Blogs or respective owner