在花费大量时间配置和尝试大量解决方案以使Artemis在
簇
模式,如
地方的
a中的模式
发布订阅
(主题)。
所以我准备了3个
消费者
在不同的
节点
和a
制作人
仅在一个节点上发布消息。
我预计这3位消费者会收到他们自己的消息副本,如中所述
here
!
问题是集群(核心网桥)仍然在3个节点之间循环消息。
我的项目Github Repo
spring-boot-artemis-clustered-topic
代理群集配置
<!-- Using STRICT is like setting the legacy forward-when-no-consumers
parameter to true-->
<!-- Using ON_DEMAND is like setting the legacy forward-when-no-consumers
parameter to false.-->
<cluster-connections>
<cluster-connection name="my-cluster">
<address>jms</address>
<connector-ref>netty-connector</connector-ref>
<retry-interval>500</retry-interval>
<use-duplicate-detection>true</use-duplicate-detection>
<message-load-balancing>ON_DEMAND</message-load-balancing>
<max-hops>1</max-hops>
<discovery-group-ref discovery-group-name="my-discovery-group"/>
</cluster-connection>
</cluster-connections>
消费者行为
artemis-b1-b2-b3