Unable to Search Human Tasks by Root Container ID

1
+1
-1

I want to find all human task belonging to a specific process and all its sub processes. However I can't seem to find away to do this despite the DB holding the relevant data.

The HumanTaskInstanceSearchDescriptor class does not contain a root container constant. However if I use the debugger to look at the object returned by searchHumanTaskInstances they clearly all have the rootContainerId field populated. I tried to set it manually but to no avail, see below.

SearchOptions searchOptions = new SearchOptionsBuilder(0, 100)
.filter("rootContainerId", item.getCaseNo())
.done();

List humanTasks = processApi.searchHumanTaskInstances(searchOptions).getResult();

Any suggestions?

Comments

Submitted by Sean McP on Wed, 12/16/2015 - 19:40

Which version are you using? Community or Subscription?

regards

Submitted by cmason on Thu, 12/17/2015 - 10:13

We are actually a partner that embeds bonita in our own application. We are using the Subscription Teamwork edition. Although to be fair I think I tested this against the org.* jar files. It just strikes me as odd the data is in the result objects but I can't search against it via the API.

So far the only way I have found to work around this is to use the API to find all the sub process IDs and add those to an OR clause. Which works but its a load more unnecessary work for me and the DB! I plan to use this after every human task is completed in our application, so I don't really want to make it any more resource intensive than I have too.

Submitted by cmason on Thu, 12/17/2015 - 10:13

We are actually a partner that embeds bonita in our own application. We are using the Subscription Teamwork edition. Although to be fair I think I tested this against the org.* jar files. It just strikes me as odd the data is in the result objects but I can't search against it via the API.

So far the only way I have found to work around this is to use the API to find all the sub process IDs and add those to an OR clause. Which works but its a load more unnecessary work for me and the DB! I plan to use this after every human task is completed in our application, so I don't really want to make it any more resource intensive than I have too.

No answers yet.
Notifications