Replay event from query side

Hallo,

I am new to axon and am in need of a working example of events replay in axon 3 on a query side model that uses rabbitMq.

thank you

Hi Anthony,

I don’t think you’ll find such example. The thing with Rabbit is, that once a messages is read, it’s gone. There isn’t much to replay.
To so a Replay in Axon 3, you need a message source that supports Streaming, and more importantly, one that also has access to all old events. Effectively, that’s you Event Store.

So if you’re in need of replays, you should use a TrackingEventProcessor that uses the Event Store as its source of events.

Cheers,

Allard

Hello Allard,

I am doing exactly same to replat events. I have a rest endpoint which I am using to trigger the event replay. The configuration is registering a event replay processor and I have the relevant entry in application.yml

  1. Application.yml

eventhandling:

processors:

eventreplayer:

mode: tracking

source: eventBus

  1. Config

@Autowired

public void configureProcessors(EventHandlingConfiguration eventHandlingConfiguration) {

// eventHandlingConfiguration.usingTrackingProcessors();

eventHandlingConfiguration.registerTrackingProcessor(“eventreplayer”);

}

  1. Using a tracking processor service as given here

http://www.techjava.de/topics/2017/10/implementing-event-replay-with-axonframework/

But still things dont seem to be working as expected.

Hi,

first of all, you don’t need to specify the tracking processor in both the EventHandlingConfiguration and the properties. One of them is enough.

Did you annotate you Event Handler class with @ProcessingGroup(“eventReplayer”) ? Note that, by default, event handlers are assigned to a processor with the name that matches the package the class is defined in. If no such processor is explicitly defined, Axon will register a Subscribing processor for it.

Cheers,

Allard