Does Apache Camel ActiveMQ component guarantees delivery message to broker?
If i understand correctly (reading this doc) Camel has persisentDelivery
configuration enabled by default for JMS and that guarantees consuming messages from broker.
But i don't understand: how it works on producing from app to broker (if yes, what kind of storage does it use)? If this kind of guarantee not supported by default, does Camel provide a simple way to implement it?
Thanks in advance
1
votes
ActiveMQ uses KahaDB database, see activemq.apache.org/kahadb.html
– Evgeniy Dorofeev
@EvgeniyDorofeev, ty, KahaDb used on broker side, but i am asking about store messages on application side in case when broker server become unavailable.
– Artur Vakhrameev
1 Answers
0
votes
No only when the message is acknowledgede by the broker its safely sent to the broker, where its guaranteed. The persistent option just tells the broker to store the message in the storage instead of keeping it in memory only.
So if Camel cannot send the message to the broker due to networking issues etc, then the operation will fail, and you would need to deal with this error in Camel.
What you can do is to have a local ActiveMQ broker alongside your Camel apps and then connect these brokers in a network of brokers where the brokers will route the messages safely among each others.