cancel
Showing results for 
Search instead for 
Did you mean: 

Actors (Owners - assignees - candidates …)

zze_one
Champ on-the-rise
Champ on-the-rise
Hi all,

Hope life is good on the Activiti side.

I have been working with workflow management for a few months and I now realize that there are more actors that the only candidates and assignees. Adding the concept of owner adds a lot of flexibility but also some complexity. I'm reading, gathering information, and trying to clarify the different concepts.

I did found in the manual and in the forum, a lot of very useful information. I do still have questions though.
Bellow is a little summary of what I think is the default organisation of the actors. By posting it, I'm hopping to provide a context around the questions that are in italic.

Thanks in advance for your help.


A candidate user
= a potential owner
Owner sounds like a better word than assignee for candidates. Am I right to think like this ?


A candidate group
= a group of potential owner


An assignee
Setting a new assignee = reassigning the task
The assignee is the human performer, the one who has to complete the task (Only one user can be assigned as human performer to the task).
He can
   - Delegate the task. Only if the task doesn't have any owner yet?
   - Resolve a task. Is there a condition such as "only if the task has a owner" or "only if the task is pending" ?
        If the assignee and the owner are the same, does the action also completes the task ?

   - Complete a task


An owner
Setting a new owner = transferring the ownership
The owner is responsible for the task: It means
   - He could be the human performer (= the assignee). By setting the owner, do I set the assignee ?
   - He can delegate the task to another user  (can we talk about reassignment ?).


Special note about the life cycle of a delegated task

If using task delegation, we have to consider the delegationState, that can be null, "pending" or "resolved".
Delegating a task sets the delegationState to "pending".
When an owner delegates the task to a user-A, the user-A becomes the new assignee. Can user-A complete the delegated task or can he only resolve it ?
When an assignee delegates the task to a user-A, the assignee becomes the new owner (This is why I'm asking if it's only possible if no owner is yet set)
Resolving the task set the delegationState to "resolved" obviously. It also set the assignee with the actual owner.
7 REPLIES 7

zze_one
Champ on-the-rise
Champ on-the-rise
Impressive how it helps to sleep on concepts you don't understand at first.
Still have a few questions (still in italic) but it's so much clearer now

A candidate user
= a potential assignee

A candidate group
= a group of potential assignee

An assignee
Setting a new assignee = reassigning the task
The assignee is the human performer, the one who has to complete the task (only one user can be assigned as human performer to the task).
An assignee can
- Delegate the task (the condition: a permission ? only if the task doesn't have any owner yet?)
- Resolve a task if the task has a different owner and delegationState == "pending"
- Complete a task if delegationState == "pending" or "null"

An owner
Setting a new owner = transferring the ownership.
I set the owner when a delegate the task, when I reassign it to someone.
The owner is responsible for the task: It means
- He could be the human performer and complete the task: When the previous assignee resolved the task)
- He can delegate the task to another user (can we talk about reassignment ?).

Special notes about the life cycle of a delegated task
If using task delegation, we have to consider the delegationState, that can be null, "pending" or "resolved".
Delegating a task set the delegationState to "pending".
When an owner delegates the task to a user-A, the user-A becomes the new assignee. Can user-A also complete the task or can he only resolves the task ?
When a assignee delegates the task to a user-A, the assignee becomes the new owner (This is why I'm asking if it's only possible if no owner is yet set)

Resolving the task set the delegationState to "resolved" obviously. It also set the assignee with the actual owner.

trademak
Star Contributor
Star Contributor
User A can also complete the task by invoking the complete method. Only via resolveTask, the task will be delegated back to the task owner.
Does that answer your question?

Best regards,

zze_one
Champ on-the-rise
Champ on-the-rise
it does, thanks Tijs

zze_one
Champ on-the-rise
Champ on-the-rise
I have one more question regarding candidates :

Is it possible to set potential owners on an entire process ?
In order for a group, described once, to be candidate on all user tasks of the workflow…

I would picture something like this :
<code>
     <process id="myProcess">
     <extensionElements>
       <activitiSmiley TongueotentialOwner>
         <resourceAssignmentExpression>
           <formalExpression>group2, group(group3), user(user3)</formalExpression>
         </resourceAssignmentExpression>
       </activitiSmiley TongueotentialOwner>
     </extensionElements>
     <startEvent id="theStart"/>
      …
</code>

Thanks,

jbarrez
Star Contributor
Star Contributor
No, you would have to store it in a variable the first time the group is determined, and use it in expression later on {{theGroup}}

zze_one
Champ on-the-rise
Champ on-the-rise
So I still have to act on the tasks once I have the value for {{theGroup}}.
Thanks Joram

jbarrez
Star Contributor
Star Contributor
Depends on what your definition of 'act on the task' is 🙂