-
Bug
-
Resolution: Done
-
Major
-
7.47.0.Final
-
None
-
False
-
False
-
NEW
-
NEW
-
Undefined
-
---
-
---
-
Not able to add task reassignment(reassignWhenNotStarted) through TaskEventListener but it fails with exception:
WARN [org.jbpm.services.task.persistence.TaskTransactionInterceptor] (default task-8) Could not commit session: java.lang.UnsupportedOperationException
at java.util.AbstractList.add(AbstractList.java:148)
at java.util.AbstractList.add(AbstractList.java:108)
at org.hibernate.collection.internal.PersistentBag.add(PersistentBag.java:411)
at org.jbpm.kie.services.impl.admin.commands.ScheduleTaskDeadlineCommand.execute(ScheduleTaskDeadlineCommand.java:69)
TaskEventListener code:
import org.jbpm.services.api.admin.UserTaskAdminService; import org.jbpm.services.api.service.ServiceRegistry; public void afterTaskActivatedEvent(TaskEvent event) { // TODO Auto-generated method stub UserTaskAdminService adminTaskService = (UserTaskAdminService) ServiceRegistry.get().service(ServiceRegistry.USER_TASK_ADMIN_SERVICE); adminTaskService.reassignWhenNotStarted(event.getTask().getId(), "60s", TaskModelProvider.getFactory().newUser("user1")); }
- incorporates
-
RHPAM-3346 Not able to add task reassignment through TaskEventListener.
- Closed