Show Table of Contents
8.3.4. グループタスクリスト
プールされたアクターはタスクの提供先候補のグループのことで、いずれかの候補がそのタスクを引き受ける必要があります。多くのユーザーが同じタスクを開始するとコンフリクトが発生してしまうため、ユーザーはグループタスクリストのタスクをすぐに開始できません。これを回避するには、ユーザーがまずグループタスクリストのタスクインスタンスのみを取得し自分のパーソナルタスクリストに移動できるようになっています。ユーザーは、自分のパーソナルタスクリストにタスクが置かれた時点のみ、タスクへの作業を開始できます。
誰かのグループタスクリストに
taskInstance を置くには、ユーザーの actorId またはユーザーの groupIdsの1つを pooledActorIds に追加する必要があります。以下のいずれかのメソッドを使い、プールされたアクターを指定します。
- このプロセスのtask要素の属性
pooled-actor-idsに表現を指定 - コードの任意の場所から
TaskInstance.setPooledActorIds(String[])を使用 - AssignmentHandlerの
assignable.setPooledActorIds(String[])を使用
あるユーザーのグループタスクリストを取得するにはユーザーのactorIdとユーザーが属するグループのすべてのIDを含むコレクションを作成します。
TaskMgmtSession.findPooledTaskInstances(String actorId) またはTaskMgmtSession.findPooledTaskInstances(List actorIds) を使用してすると、パーソナルタスクリストに存在せず(actorId==null)、プールactorIdにマッチしないタスクインスタンスを検索できます。
注記
当ソフトウェアは、アイデンティティコンポーネントを JBPM タスク割り当てと分けるよう設計されました。JBPM は actorId として文字列のみを保管し、ユーザー、グループ、他の ID 情報間の関係は認識しません。
actorId は常にプールアクターよりも優先されます。 したがって、 actorId と
pooledActorId のリストを持つ taskInstance はアクターのパーソナルタスクリストにのみ現れます。また、タスクインスタンスをグループに配置しなおすためにpooledActorIdを保持しますが、これはtaskInstanceの actorId プロパティを null に設定するだけで行うことができます。

Where did the comment section go?
Red Hat's documentation publication system recently went through an upgrade to enable speedier, more mobile-friendly content. We decided to re-evaluate our commenting platform to ensure that it meets your expectations and serves as an optimal feedback mechanism. During this redesign, we invite your input on providing feedback on Red Hat documentation via the discussion platform.