I’m surveying persistence/architecture options for a new application and I’m not very knowledgeable about Axon yet. I hope you can help me with the following question.
I am interested in using Event Sourcing with either a relational database or MongoDB.
The application should write some events to Kafka – maybe a subset of the internal events or some summary events but not all internal events.
To write to Kafka, I want to use the Outbox pattern to achieve guaranteed delivery.
That is, the events for Kafka should be written to an “outbox” database table first and later be written to Kafka using Debezium.
See Reliable Microservices Data Exchange With the Outbox Pattern
Is that possible/sensible with Axon? How? Any comparable examples?
Could I control exactly what is written to the Outbox table?
I have seen that the Kafka extension exists.
It does not seem appropriate for my requirements.
An end user may perform an action that leads to “SomethingHappened”.
The write to Kafka may not be possible at the moment because of a network issue.
It does not make sense to wait for X seconds and then undo the transaction and interfere with the user flow.
But I still need to guarantee the Kafka event.
The outbox pattern is a classic approach for this.