I realize I've asked questions like these before, but the threads wandered off the topic.
I'd have to think there are enumerators for all processinstances, taskinstances, etc., but I haven't found them. One answer was to write your own query against the hibernate db, but that bypasses the API and is dangerous from an upgrade standpoint.
Are there global enumerators or list methods for all these objects? If not, doesn't that seem like an omission?
what happens if you try an actor of '%' or '*' or likewise
Thanks, I'll try...
Unfortunately wild card doesn't work because the query in "hibernate.queries.hbm.xml" is:
<query name="TaskMgmtSession.findTaskInstancesByActorId"> <![CDATA[ select ti from org.jbpm.taskmgmt.exe.TaskInstance as ti where ti.actorId = :actorId and ti.isSuspended != true and ti.isOpen = true ]]> </query>
I tried changing the
where ti.actorId = :actorIdto
where ti.actorId like :actorIdin the "hibernate.queries.hbm.xml" file embedded in the "jbpm-jpdl.jar", and then the wildcard worked (using an Oracle9 connection, by the way).
List taskList = jbpmContext.getTaskList("%");
Again, making a custom jBPM library is a maintenance worry. I hope the developers will give us an API for getting the complete task list. Our need is to be able to filter the complete list by various groups of users or other criteria.
One of the beauties of open source is that you *can* develop extensions. Yes, they are a little difficult to maintain, but at least you *can* do it. Instead of changing the current API, you can extend it which is a little less worry to maintain ;-)
But you can always file a jira issue for this. Not sure if it will be accepted, but you'll never know.