cancel
Showing results for 
Search instead for 
Did you mean: 

Task Query (All Tasks)

pneudecorb
Champ in-the-making
Champ in-the-making
Is it possible to query the engine for all tasks, even ones that haven't been reached yet in the current execution, If so, how?

I'm creating an onboarding workflow and I need to be able to display all the tasks whether they are active or not.
4 REPLIES 4

ronald_van_kuij
Champ on-the-rise
Champ on-the-rise
Why would you? I you could show them (depending on you flow, some might never be reached) you could not act on them.

Please state your usecase…

pneudecorb
Champ in-the-making
Champ in-the-making
I understand how a workflow engine works and I understand that some activities may never be reached depending upon how that process definition is designed.

I am using the workflow engine for an onboarding process and whether or not a segment in the flow will be reached at run time, I still need to present to a particular user, which activity(ies) they could be responsible for….

For example, consider you have a simple on boarding process with the following activities

1) Provision Laptop
2) Distribute Laptop
3) Assign Access Badge

Now consider that activity 1 and 2 are both done by IT but activity 2 is gated (blocked) until activity 1 is completed.
Activity 3 is performed by HR.

I have a requirement to present ALL the possible activities to each user, so in this case,

The IT user would have both Activity 1 and 2 as their future actionable items even though Activity 2 might not ever get activated in the flow.
The HR user would have Activity 3 show up in their list of activities.

Makes sense?

pneudecorb
Champ in-the-making
Champ in-the-making
I'm currently investigating the Process Definition Query functionality available through the Repository Service.

It looks like I can get to the task information I need by casting my single result to a ProcessDefinitionEntity.

pneudecorb
Champ in-the-making
Champ in-the-making
My thought of querying for a Process Definition, casting it to a ProcessDefinitionEntity didn't bear fruit…when I check the instance variables for defined activities, it returns an empty list, so I am still unable to identify all the task definitions for a process definition.

Any ideas?