Batch with 10K items does NOT work

Hi,
My name is Victor, Tech Lead and Architect at Yotpo.

We are currently evaluating camunda 8 as our microservices orchestration solution.
In addition, we are trying to understand if we can use it for batch jobs.

I have created a POC project and trying different scenarios.

Here is the code for the batch POC I am trying:


@SpringBootApplication
@EnableZeebeClient
public class BatchItems {

    private static final Logger log = LoggerFactory.getLogger(BatchItems.class);


    public static void main(String[] args) {
        SpringApplication.run(BatchItems.class, args);
    }

    @ZeebeWorker(type = "create-items", autoComplete = true)
    public Map<String, Object> createItems(final @ZeebeVariable Integer count) {

        log.info("Starting create-items, count: {} ", count);

        // Probably add some process variables
        HashMap<String, Object> variables = new HashMap<>();
        List<String> items = IntStream.range(1, count)
            .boxed()
            .map(i -> "item"+i)
            .collect(Collectors.toList());
        return  Collections.singletonMap("items",items);
    }

    @ZeebeWorker(type = "item-processor", autoComplete = true)
    public void itemProcessor(final @ZeebeVariable String item) {

        log.info("Starting item-processor, item: " + item);

    }

    @ZeebeWorker(type = "notify-done", autoComplete = true)
    public void notifyDone(@ZeebeVariable Collection<String> items) {

        log.info("Completed, items count: " + items.size());

    }
}

When I run this scenario with 10K items it hangs and then starts after a while.
The issue is that only part of ‘item-processor’ tasks are actually starting.
The process remains in the ‘running’ state and those tasks never started/accomplished.

Pls find my project here: GitHub - victor-prp/camunda-poc

Pls advice.
Many thanks
Victor

Hi Victor.
What’s the environment you are running in? Is it Camunda 8 SaaS? Or do you spin up your own self-managed cluster (if so - what’s its configuration)?
Best
Bernd

Hey @victor-prp

sounds like you run into a limitation of the Zeebe system see here I can spawn inner instances for a large input collection · Issue #2890 · camunda/zeebe · GitHub

I hope we can fix this sooner than later.

Greets
Chris

I am using managed trial account (Camunda 8 Saas).
Pls see the details here: camunda-poc/application.properties at main · victor-prp/camunda-poc · GitHub

Heu Zelldon.
Thanks for the answer.

I am trying to evaluate Camunda 8 for batch processing.
In this scenario the number of items to be processed can be very large: lets say up to 1Bil.

What is the suggested pattern to use in batch cases?
Is my model is correct or should I go with a different solution in order to avoid big parameters?
Can you pls propose a batch example that handle it properly?

Many thanks
Victor