Saga - Axon-Trader

Hi all,

Im newbie in Axon framework. I have a question on Axon-trader project:

  • Why at the end of saga the commandbus continues dispatch a command ? Why dont execute it in saga ?

Someone explain this for me. Pls !

Thank so much !


The goal of a Saga is to coordinate a ‘complex business transaction’ between several aggregates.
It does this by listening to events from several aggregates, retrieving and storing state from those events internally.
On certain event handlers and after state changes, it makes a decision to perform a command on an aggregate.
As it is the coordinator between aggregates, it thus is not the executor of the action; that’s not what it is designed for.
Hence it tells the designated aggregate to perform the action by publishing a command.

Hope this give you some insight.
Otherwise maybe the reference guide can shed some extra light on this situation for you.

Hope this helps!