gpt4 book ai didi

msmq - 连接到专用远程 MSMQ 队列

转载 作者:行者123 更新时间:2023-12-04 15:49:31 26 4
gpt4 key购买 nike

我正在尝试使用以下路径连接到远程私有(private) MSMQ 队列:

"FormatName:DIRECT=OS:remoteMachineName\Private$\MyQueue"

我收到以下错误:
"The specified format name does not support the requested operation. For example, a direct queue format name cannot be deleted."

我显然做错了什么。但是,这确实可以使用本地队列。

我正在使用 Spring.Net 的 Messaging .这是我的配置

<objects xmlns="http://www.springframework.net">
<object id="myQueue" type="Spring.Messaging.Support.MessageQueueFactoryObject, Spring.Messaging">
<property name="Path" value="FormatName:DIRECT=OS:remoteMachineName\Private$\MyQueue"/>
</object>

<object id="messageQueueTemplate" type="Spring.Messaging.Core.MessageQueueTemplate, Spring.Messaging">
<property name="DefaultMessageQueueObjectName" value="myQueue"/>
</object>

<object id="messageGateway" type="My.MessageGateway, My.Assembly">
<property name="MessageQueueTemplate" ref="messageQueueTemplate"/>
</object>
</objects>

最佳答案

这是一个事务队列吗?无法从事务队列远程读取。也许spring框架会尝试检查这是否是一个事务队列,这也是一个仅在本地队列上支持的操作。

推荐使用队列的原因是写入远程队列并从本地队列读取。在 msmq 4.0(vista 和 windows 2008)中支持远程事务读取(所以我听说过)。

您可以调试 spring.net 代码并在进程失败时查看确切的代码吗?

关于msmq - 连接到专用远程 MSMQ 队列,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/376208/

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