<?xml version= "1.0" encoding= "UTF-8"? ><beans xmlns= "http://www.springframework.org/ Schema/beans " xmlns:context=" Http://www.springframework.org/schema/context " xmlns:xsi= "Http://www.w3.org/2001/XMLSchema-instance" xsi:schemalocation= " Http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans /spring-beans-4.1.xsd http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-4.1.xsd "> <!-- Connection Pool --> <bean id= "Pooledconnectionfactory" class= " Org.apache.activemq.pool.PooledConnectionFactory " destroy-method=" Stop "> <property name= "ConnectionFactory" > <bean class= "Org.apache.activemq.ActiveMQConnectionFactory" > <property name= " Brokerurl " value=" tcp://localhost:61616 " /> </bean> </property> </bean> <!-- Connection Factory --> <bean id= "Activemqconnectionfactory" class= " Org.apache.activemq.ActiveMQConnectionFactory "> < Property name= "Brokerurl" value= "tcp://localhost:61616" /> < /bean> <!-- Configure message Destination --> <bean id = "Destination" class= "org.apache.activemq.command.aCtivemqqueue "> <constructor-arg index=" 0 " value= "Com.netease.mobile.device,com.netease.urs" /> </bean> <!-- Message template --> <bean id= " Jmstemplate " class=" Org.springframework.jms.core.JmsTemplate "> <property name= "ConnectionFactory" ref= "Activemqconnectionfactory" /> <property name= "DefaultDestination" ref= " Destination " /> <property name=" Messageconverter "> <bean class= "Org.springframework.jms.support.converter.SimpleMessageConverter" /> </property>&Nbsp; </bean> </beans>
ACTIVEMQ and spring integration, producer-side configuration