ActiveMQ Bridge Connection

Source: Internet
Author: User

1.ActiveMQ Network Bridging 1.1 ActiveMQtransmission Mode

ActiveMQ by means of communication: bridging and forwarding and bidirectional communication

1. bridging forwarding is a Broker that passes messages to another ActiveMQ .

2. Two-way communication is the use of a channel can either receive messages or send messages.

The message that is pushed to Broker1 is automatically forwarded to Broker2 ,Broker2 does not need to modify any settings, only Broker1 you can make changes.

1.2ActivemqNetwork Bridging configurationBin/activemq.xml

<bean id= "Bridgedbroker" class= "Org.apache.activemq.broker.BrokerService" init-method= "Start" destroy-method= " Stop ">

<property name= "Brokername" value = "Bridgedbroker"/>

<property name= "Persistent" value= "false"/>

<property name= "Transportconnectoruris" >

<list>

<!-- message production queue --

<value>tcp://localhost:61616</value>

</list>

</property>

<property name= "Jmsbridgeconnectors" >

<list>

<bean class= "Org.apache.activemq.network.jms.JmsQueueConnector" >

<property name= "Outboundqueueconnectionfactory" >

<bean class= "Org.apache.activemq.ActiveMQConnectionFactory" >

<!-- consumer queue address --

<property name= "Brokerurl" value= "tcp://10.1.230.200:61616"/>

</bean>

</property>

<property name= "Outboundqueuebridges" >

<list>

<bean class= "Org.apache.activemq.network.jms.OutboundQueueBridge" >

<!-- only forward the message queue --

<constructor-arg value= "Messages.input"/>

</bean>

</list>

</property>

</bean>

</list>

</property>

</bean>

1.3Example

Scene:

After the native ActiveMQ is started, after the queue is created, then click Send to send a message to the queue.


Third-party queues are default empty after they are started.

After we send a message to the first MQ , we should forward the message through our configured address. This way, the second MQ should receive A message that is forwarded over ten.

Copyright NOTICE: This article for Bo Master original article, without Bo Master permission not reproduced.

ActiveMQ Bridge Connection

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.