gpt4 book ai didi

ibm-mq - MQ Pub/Sub 主题到队列桥接

转载 作者:行者123 更新时间:2023-12-04 06:37:40 24 4
gpt4 key购买 nike

在其他队列管理器中,可以在队列和主题之间建立一个桥梁,这样发布者和订阅者就不需要知道他们正在使用一个主题:

TIBCO EMS 中的示例

create Bridge source=queue:QName target=topic:TName
create Bridge source=topic:TName target=queue:QName



我如何在 WMQ 中执行此操作?

最佳答案

见 WebSphere MQ V7.0 Features and Enhancements第 47 页,它提到了使用别名队列和管理订阅

WebSphere MQ V7.0 introduces an extension to the alias queue object that allows it to be resolved to the new topic object. This is useful for migrating point-to-point messaging applications to the Publish/Subscribe model. A traditional point-to-point application that puts messages into WebSphere MQ can operate as a publisher without any code changes by utilizing an alias queue that resolves to a topic object. This is implemented administratively by defining a topic object that maps to an appropriate topic string on which the messages are to be published. The original local queue is deleted and replaced by an alias queue of the same name that resolves to the topic object. Also note that a point-to-point application that gets messages from WebSphere MQ can operate as a subscriber without any code changes by defining an administrative subscription to a topic.



第 220 页的示例 9.3 显示了如何设置从主题到目标队列的管理订阅
DEFINE SUB(SUB.RETAIL.CAT) TOPICOBJ(MATT.RETAIL.CAT) DESTCLAS(MANAGED)
DEFINE SUB(SUB.MATTRETCAT) TOPICSTR(‘matt/retail/cat’) DESTCLAS(MANAGED)
DEFINE SUB(SUB.PROVCAT) TOPICSTR(‘matt/retail/cat’) DEST(SUB.PROVCAT.DESTQ)

关于ibm-mq - MQ Pub/Sub 主题到队列桥接,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/4666467/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com