flowable / flowable/flowable-engine

MultiInstance External Worker Task

Open
#3,053 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Java
Stars
9.5k
Forks
2.9k
Avg merge
7h 8m
Merged PRs (30d)
2

Description

**Describe the bug**
When there is more than one task is created for a multi-instance external worker task, the job acquirer returns no jobs to process. Multi-instance loop for task is parallel.

**Expected behavior**
All external worker jobs can be acquired via API.

**Code**

service task
```




```

Java code to check
```
Map startData = new HashMap<>();
startData.put("initials", Arrays.asList("1", "2"));

ProcessInstance processInstance = runtimeService.startProcessInstanceByKey("bug1", startData);

List acquiredJobs = managementService.createExternalWorkerJobAcquireBuilder().topic("Task1Topic", Duration.ofSeconds(5)).acquireAndLock(5, "worker1");

Assertions.assertEquals(2, acquiredJobs.size());
```

**Additional context**

- It is ok, when there is only one task is created for the multi-instance
- It is ok, when `isSequential=true`

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.