简体   繁体   English

WSO2 ESB连接到远程消息代理队列

[英]WSO2 ESB connect to remote message broker queue

I have managed to send messages to a local message broker queue from wso2 esb. 我已设法从wso2 esb向本地消息代理队列发送消息。

However I am having trouble sending message to a remote queue. 但是,我在将消息发送到远程队列时遇到问题。 I thought if I included the server in the physical queue name in JNDI.properties this would work but it does not. 我想如果我将服务器包含在JNDI.properties中的物理队列名称中,这将起作用,但事实并非如此。

Anyone have any suggestion what config is to send messages to a remote message broker queue from ESB? 任何人都有任何建议是什么配置从ESB发送消息到远程消息代理队列?

Cheers Macca 干杯马卡

Bit more information 更多信息

Error I get is :- ERROR - AMQConnection Throwable Received but no listener set: org.wso2.andes.client.AMQNoRouteException: Error: No Route for message [error code 312: no route] 我得到的错误是: - 错误 - AMQConnection Throwable收到但没有监听器设置:org.wso2.andes.client.AMQNoRouteException:错误:没有消息路由[错误代码312:无路由]

Files I am using:- 我正在使用的文件: -

jndi.properties jndi.properties

connectionfactory.ConnectionFactory = amqp://admin:admin@clientID/carbon?brokerlist='tcp://localhost:5673'

queue.myRemoteQueue = \\ServerName\myQueue

axis2.xml axis2.xml

<transportSender name="jms" class="org.apache.axis2.transport.jms.JMSSender"> 
        <parameter name="default" locked="false"> 
            <parameter name="java.naming.factory.initial"   locked="false">org.wso2.andes.jndi.PropertiesFileInitialContextFactory</parameter> 
            <parameter name="java.naming.provider.url" locked="false">repository/conf/jndi.properties</parameter> 
            <parameter name="transport.jms.ConnectionFactoryJNDIName" locked="false">ConnectionFactory</parameter> 
        </parameter> 
</transportSender>

ESB Proxy Service ESB代理服务

<?xml version="1.0" encoding="UTF-8"?>
<proxy xmlns="http://ws.apache.org/ns/synapse"
       name="Test2JMS"
       transports="https,http"
       statistics="disable"
       trace="disable"
       startOnLoad="true">
   <target>
      <inSequence>
         <log level="custom">
            <property name="STATE" value="message is sent to queue"/>
         </log>
         <property name="OUT_ONLY" value="true"/>
         <property name="FORCE_SC_ACCEPTED" value="true" scope="axis2"/>
      </inSequence>
      <outSequence/>
      <endpoint>
         <address uri="jms:/myRemoteQueue?&amp;transport.jms.DestinationType=queue"/>
      </endpoint>
   </target>
   <description/>
</proxy>

You are missing some information in your JMS address. 您缺少JMS地址中的一些信息。 Please refer https://docs.wso2.com/display/ESB481/ESB+as+a+JMS+Producer for the proper format. 请参考https://docs.wso2.com/display/ESB481/ESB+as+a+JMS+Producer了解正确的格式。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM