ActiveMq:持久队列和离线系统

时间:2017-06-19 10:07:39

标签: c++ activemq activemq-cpp

我是ActiveMQ技术的新用户,我在使用这项技术时遇到了一些问题。

我有以下情况:

  1. 我有一个在嵌入式(离线)ARM设备中运行的SW,它在运行时将一组视频存档在可上载的硬盘上。
  2. 有时候(每天4-5个事件),我必须将警报事件与这些视频相关联,并将警报排入持久队列。
  3. 每月一次,我们必须提取硬盘并将其连接到另一个嵌入式在线 ARM设备,该设备应该通知ActiveMQ服务器有关脱机ARM设备生成的警报< /强>
  4. 现在我的问题是:如何将持久性队列存储在硬盘上,以便离线ARM设备生成的事件可供在线ARM系统使用(在线和之间唯一的“连接”)离线嵌入式设备是硬盘)?

    请注意,我无法更改向在线服务器传输邮件的方式,因为它是我公司未开发的系统。

    祝你好运

    乔瓦尼

1 个答案:

答案 0 :(得分:1)

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