EventProcessor with thread pool

we are running Axon framework with Spring boot starter, but with AxonServer disabled. Recently I’ve noticed all events are processed by the same thread blocking each other while processing.

Is there a way how to configure event processor to use thread pool?

I tried to configure EventProcessorProperties in yml by setting the axon.eventhandling.processors, but the result was that the event processor of other saga has been used.

Thanks Tomas

Ok, I got it. Need to set @ProcessingGroup(“taskProcessingGroup”) on the particular event handler class to distinguish the processing group first.

Unfortunately, the mode is then set by SUBSCRIBING and I need to “reset” it to TRACKING manually. But this has already bug reported I guess

then I can set:


        initialSegmentCount: 2
        threadCount: 2
        mode: TRACKING


Hi Tomáš,

The Subscribing-as-default comment points to the fact you’re using Axon 3 instead of Axon 4.

Axon 4 deliberately changed the default to Tracking, as this is very likely the way to go for any Axon Framework application.
Thus, that you’re seeing it set to subscribing is by design if your in an Axon 3 application.

Additionally, when it comes to configuring your Event Processors, Processing Groups and potential multiple threads and TrackingToken segments, all that knowledge should be described on this Reference Guide page.
Regardless, thanks for posting your question Tomáš, but also for sharing the solution you found.