If a command causes more commands should I use Saga or simply autowire CommandGateway into the handler?

I am new to the framework, just recently discovered Sagas.
In my case, I also want to ensure that these commands are called in the order and only call next if previous succeeds. Because of that, I call #sendAndWait on the command gateway for a couple of commands before exiting my command handler method in the aggregate. Is this a correct usage or should I look at Saga?

Just noticed that I actually cannot test that commands were dispatched with an aggregate fixture, only with saga test fixture, which gives Sagas more preference now

Hi Sam,

If you want to dispatch consecutive commands, there is no immediate requirement to use Sagas at all.
Sagas are intended to model complex business transactions which have a notion of time in them.

If you just want to react once to an event and dispatch several commands on it, a regular Event Handler which uses the CommandBus/CommandGateway should be sufficient.

To validate the commands occur in order, you can indeed use the CommandGateway#sendAndWait method.
You can however also leverage the strength of the CompletableFuture which is given to you on a CommandGateway#send call.
With that, you can wait until the CompletableFuture is resolved and only after that dispatch another commands.
Additionally, it gives you a handle to deal with potential exceptions being thrown from your Command Handler.

Lastly, I don’t understand your last sentence, why the SagaTestFixture would have preference in this scenario.
Note that the test fixtures provides by the framework or in place to either test Aggregate logic or Saga logic.
So, they are not intended to be used for regular message handling functions, at all.

Hope this sheds some light on the situation Sam.