如何在WSO2ESB和WSO2 MB中设置端口

时间:2015-01-19 09:36:01

标签: wso2 wso2esb wso2carbon qpid

使用WSO2 ESB 4.7.0和WSO2 MB 2.2.0。

我已按照以下链接在WSO2 ESB和WSO2 MB之间进行了整合:

https://docs.wso2.com/display/MB220/Integrating+WSO2+ESB

我已经使用端口成功启动了MB服务器,如下所示

[2015-01-19 14:32:20,868]  INFO {org.wso2.andes.server.cluster.GlobalQueueManager} -  Starting Global Queue Worker for Global Queue : GlobalQueue_9
[Broker] BRK-1002 : Starting : Listening on TCP port 5675
[2015-01-19 14:32:26,132]  INFO {qpid.message.broker.listening} - [Broker] BRK-1002 : Starting : Listening on TCP port 5675
[Broker] BRK-1002 : Starting : Listening on TCP/SSL port 8675
[2015-01-19 14:32:26,138]  INFO {qpid.message.broker.listening} -  [Broker] BRK-1002 : Starting : Listening on TCP/SSL port 8675
[Broker] BRK-1004 : Qpid Broker Ready

当我启动ESB服务器时,它显示错误,如下所示

[2015-01-19 14:37:34,275]  INFO - AMQConnection Unable to connect to  broker at tcp://localhost:5672
 org.wso2.andes.transport.TransportException: Could not open connection
at org.wso2.andes.transport.network.mina.MinaNetworkTransport$IoConnectorCreator.connect(MinaNetworkTransport.java:216)
at org.wso2.andes.transport.network.mina.MinaNetworkTransport.connect(MinaNetworkTransport.java:74)
at org.wso2.andes.client.AMQConnectionDelegate_8_0.makeBrokerConnection(AMQConnectionDelegate_8_0.java:120)
at org.wso2.andes.client.AMQConnection.makeBrokerConnection(AMQConnection.java:616)
at org.wso2.andes.client.AMQConnection.<init>(AMQConnection.java:398)

我不确定,但我认为esb尝试连接到代理的端口不匹配,有没有办法更改此端口连接成功到代理..?

帮助我。

1 个答案:

答案 0 :(得分:1)

因为,您有3作为端口偏移,请执行以下操作

打开<ESB_HOME>/repository/conf/JNDI.proerties文件并指向正在运行的Message Broker。

使用carbon作为虚拟主机。定义名为JMSMS的队列。在不需要的情况下评论该主题。但是,为了避免在服务器启动期间获得javax.naming.NameNotFoundException: TopicConnectionFactory,请将TopicConnectionFactory指向Message Broker。

# register some connection factories
# connectionfactory.[jndiname] = [ConnectionURL]
connectionfactory.QueueConnectionFactory = amqp://admin:admin@clientID/carbon?brokerlist='tcp://localhost:5675'
connectionfactory.TopicConnectionFactory = amqp://admin:admin@clientID/carbon?brokerlist='tcp://localhost:5675'
# register some queues in JNDI using the form
# queue.[jndiName] = [physicalName]
queue.JMSMS=JMSMS
queue.StockQuotesQueue = StockQuotesQueue