Microservices and Axon


I’m working on a platform where microservices publish events to a central message bus.
Some of these events should trigger a new aggregate instance in one or more services.

Should I use a Saga to convert the events to commands?

msg --> IncomingEventHandler --> Saga --> Aggregate

This looks like a lot of plumbing.

Another option would be to deserialize the messages as commands and send them through the gateway.

Any thoughts?



if the translation of Events to Commands is really simple, a singleton EventListener would be sufficient. Only if the translation is more complex and requires some state, then Sagas would be a good option.

I’ve thought of using Events of one context as Commands in another, but the idea gives me too much of an itch. Especially because the ubiquitous language is often different: “when X happened, we do Y”. X would be an event from one context, and Y the command of the other.