I have a scenario where I'm using Aeron messaging library with multiple consumers consuming from the same channel. I want to ensure that each message is consumed by only one consumer to avoid duplication and guarantee consistency across consumers. In Kafka, we have the concept of committing offsets to track the progress of each consumer. Is there a similar mechanism or approach in Aeron to achieve message consumption consistency?
In my setup, I have multiple consumers that subscribe to the same Aeron channel and I want to make sure that messages are distributed across consumers in a balanced manner. I'm aware that Aeron provides a broadcast approach by default, where each consumer receives a copy of every message. However, I'm interested in a scenario where each message is consumed by only one consumer.
I have explored the Aeron documentation and API, but I couldn't find a built-in mechanism similar to Kafka's offset committing. I would like to know if there are any recommended patterns or techniques to achieve message consumption consistency in Aeron with multiple consumers.
My specific requirements are as follows:
Guarantee that each message is consumed by only one consumer to avoid duplication. Ensure consistency across consumers, so that no two consumers process the same message in same channel. Ideally, have a mechanism to track the progress of each consumer, similar to Kafka's offset committing. I would appreciate any insights, recommendations, or best practices for handling this scenario in Aeron. If there are any C++ code examples or configuration suggestions, they would be highly valuable.
Thank you in advance for your help!