Awesome to hear you are making the shift from Axon Framework 2 to 4! I am confident the upgrade will bring you a suit of new additional features and enhancements you can base your application on.
Interesting to hear that some of your clients aren’t using the Event Store here. Does that in your scenario also mean they are not publishing/using any event messages? And, I assume they still have aggregates in their application too. Does that mean those aggregates are not event sourced, but use the state-stored solution instead?
Knowing those extra bits I’ve just requested might change my answer slightly. So it would be valuable if you could post those in an upcoming reply. For now though, let’s move over to your question on how to configure Axon Server to not be an Event Store.
When it comes to running Axon Server, there is no real means to tell it not to be an Event Store. So essentially, it will always build up the required components to this end to fulfill both the Messaging Platform and Event Storage requirements. Hence, the configuration lies within the client (read: the Axon Framework application) to not use the (auto) configured Axon Server Event Store, but replace it by your own solution. This is where my questions become important, as it is currently not 100% obvious to me whether events are at all being used.
If they are, you will still require the usage of an EventBus
, for which I would recommend the SimpleEventBus
. Configuring can roughly go two ways:
- By providing a
SimpleEventBus
in a Spring Boot environment, it will automatically replace any other auto configured beans, like the Axon Server Event Store.
- Through Axon’s
Configurer
you can use the configureEventBus
.
Furthermore, you might or might not be running this application you are describing in a distributed environment, thus I mean you have several Axon applications talking to one another through commands, events and queries. This is were you might hit a roadblock at the moment, as Axon Server can only serve the purpose of distributing events if it is also an Event Store. Hence by not using it is an Event Store, you will loose the possibility to distributed event messages between application. You would thus be required to configure the AMQP Extension for example to be able to achieve this again.
Long story short, you have to configure a SimpleEventBus
as the event bus used in your application and you are done. Whether this is sufficient in your scenario however depends on a more fine grained explanation of your application.
Regardless, I hope this helps!