能否在同一源服务器和目标服务器之间配置 Apache ActiveMQ Artemis 服务器上的核心桥

Can a core bridge on Apache ActiveMQ Artemis Server be configured between the same source and destination server

我想了解是否在同一源服务器和目标服务器之间配置了 Apache ActiveMQ Artemis 服务器上的核心桥。我这样做的原因是因为我的发布者将消息写入队列 A 和队列 B,但我的订阅者只收听队列 AB。所以我的意图是将队列 A 和 B 桥接到队列 AB 中。来自 Artemis user manual 我读到:

The function of a bridge is to consume messages from a source queue, and forward them to a target address, typically on a different Apache ActiveMQ Artemis server

In summary, bridges are a way to reliably connect two separate Apache ActiveMQ Artemis servers together. With a core bridge both source and target servers must be Apache ActiveMQ Artemis servers.

我不清楚源服务器和目标 Artemis 服务器是相同的还是需要不同。

从技术上讲,我不明白为什么核心网桥不能具有相同的源和目标代理。但是,这不是必需的。您可以简单地为您的用例使用 divert 。正如文档所述:

Diverts allow you to transparently divert messages routed to one address to some other address, without making any changes to any client application logic.