以编程方式将 Oracle BPEL 任务标记为完成
我正在使用 Oracle BPEL 流程管理器,并将一项任务分配给一组用户。 我尝试使用 Java 类 oracle.bpel.services.workflow.task.ITaskService.updateTaskOutcome() 将其标记为已批准。 如果将任务分配给单个用户,则此方法有效,但如果将任务分配给一组用户,我会收到有关未获取任务的错误消息。
如果我使用 oracle.bpel.services.workflow.task.ITaskService.acquireTask() 获取任务,则在尝试将其标记为已批准时收到一条错误消息:“该任务已被其他用户获取”。
任何人都可以指出以编程方式更改分配给组的 Oracle BPEL 任务状态的示例代码吗?
I am using Oracle BPEL Process manager and have a task assigned to a group of users.
I try to mark it approved using Java class oracle.bpel.services.workflow.task.ITaskService.updateTaskOutcome(). This works if the task is assigned to an individual user, but if the task is assigned to a group of users, I get an error message about the task not being acquired.
If I acquire the task using oracle.bpel.services.workflow.task.ITaskService.acquireTask(), I get an error message when trying to mark it approved: "The task has been acquired by some other user".
Can anybody point to sample code that changes status of an Oracle BPEL task assigned to a group programmatically?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
当分配给多个用户时,使用
updateTaskOutcomes()
方法而不是updateTaskOutcome()
use
updateTaskOutcomes()
method instead ofupdateTaskOutcome()
when it is assigned to multiple users您的第一个问题似乎很明显,您无法批准分配给某个组而不首先获取的任务。 否则,该任务是由小组中的哪位成员批准的?
您的第二个问题是您正在向一个用户获取任务并尝试向另一位用户批准该任务。
要真正找到问题所在,您可以获取任务,然后转到元数据库并搜索谁获取了该任务。 我想这会让您更好地了解实际发生的情况。
Your first problem seems obvious, you cannot approve a task that it is assigned to a group without first acquiring. Otherwise, which member of the group had approved the task?
Your second problem is that you are acquiring the task with one user and trying to approve it with another user.
To actually find where the problem is, you can acquire the task and then go to the meta db and search who has acquired the task. I guess that will give you a better picture of what is actually happening.