EventProcessorLatencyMonitor for TrackingEventProcessor

Hi All,

Lately we have been facing performance issues related to a TrackingEventProcessor. The TEP has been in production for a number of years but lately it has been a bottleneck. The - single segmented - TEP cannot handle peak loads. To be precise the TEP is ok, rather the event handlers that it feed are problematic.
We where pleased to find the axon-metrics module (part of Axon 3.0) and added the CapacityMessageMonitor and EventProcessorLatencyMonitor monitors to the TEP and ran some tests under load. Unfortunately the latency monitor always reports “0” despite capacity averaging around 1 and the TEP not keeping up with the latest domain events published in the event store.

My understanding is (based on the java docs) the latency monitor measures the period between publication of an event and the time it gets picked up by the TEP for handling. So when TEP can keep up with event publication, latency would near zero
A quick glance at the code however revealed the EventMessage.getTimestamp() method used by the latency monitor does not correspond to the DOMAIN_EVENT_ENTRY.TIME_STAMP column of the (jpa) event store.
Is this expected or am I incorrectly using the latency monitor?


Hi @Benoit_Liessens,

Sorry for skipping this issue. Actually assumed it was picked up, as you provided a pull request.
As you noticed though, your assumption is correct and you have found a bug. Thanks again for fixing it!

As it stands, the fix is scheduled for 4.4.4.
Pretty confident this will be release somewhere in the upcoming weeks, so stay tuned!