c++activemq-classicactivemq-cpp

ActiveMq: persistent queue and offline system


I'm a fresh user of ActiveMQ technology, and I have some problem approaching this technology.

I have the following situation:

  1. I have a SW, running in a embedded (offline) ARM device, that archive a set of videos on a upluggable hard disk at run time.
  2. Sometimes (4-5 events a day), I have to associate a alarm event to those videos and to queue the alarm on a persistent queue.
  3. Once a month we have to extract the hard disk and to connect it to another embedded online ARM device, that should notify a ActiveMQ server about the alarms generated by the offline ARM device

And now my question: how can I store the persistent queue on the hard disk, so that the events generated byt the offline ARM device will be available to the online ARM system (the only "connection" between online and offline embedded device is hard disk)?

Please note that I cannot change the way I transmit messages to the online server, since it is a system not developed by my company.

Best regards

Giovanni


Solution

  • It sounds like you want a "store-and-forward" messaging pattern. You could configure the "offline" ActiveMQ broker to attempt to connect to the "online" ActiveMQ broker. The network connector will attempt to connect at configurable intervals and when it is "online" it will begin to send messages automatically.

    The slight down side is that the broker will attempt to connect to the remote broker (even when offline), so you'll need to manage log rotation or logging levels to accommodate.

    Look for the static:// network connector uri

    Network of brokers