Fix to support spring 2.0, connections produced with SingleConnectionFactory do not allow you to set the clientId on the connection.

git-svn-id: https://svn.apache.org/repos/asf/incubator/activemq/trunk@467715 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Hiram R. Chirino 2006-10-25 17:12:14 +00:00
parent be0aaf481f
commit e281f0645a
6 changed files with 42 additions and 7 deletions

View File

@ -45,6 +45,11 @@
</property>
</bean>
<bean id="consumerJmsTemplate"
class="org.springframework.jms.core.JmsTemplate">
<property name="connectionFactory" ref="jmsFactory"/>
</bean>
<!-- a sample POJO which uses a Spring JmsTemplate -->
<bean id="producer" class="org.apache.activemq.spring.SpringProducer">
<property name="template" ref="myJmsTemplate" />
@ -55,7 +60,7 @@
<!-- a sample POJO consumer -->
<bean id="consumer" class="org.apache.activemq.spring.SpringConsumer">
<property name="template" ref="myJmsTemplate" />
<property name="template" ref="consumerJmsTemplate" />
<property name="destination" ref="destination" />
</bean>

View File

@ -17,7 +17,9 @@
-->
<!-- START SNIPPET: spring -->
<beans xmlns="http://www.springframework.org/schema/beans" xmlns:amq="http://activemq.org/config/1.0"
<beans
xmlns="http://www.springframework.org/schema/beans"
xmlns:amq="http://activemq.org/config/1.0"
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.xsd
http://activemq.org/config/1.0 http://people.apache.org/repository/org.apache.activemq/xsds/activemq-core-4.1-incubator-SNAPSHOT.xsd">
@ -48,6 +50,10 @@
</property>
</bean>
<bean id="consumerJmsTemplate" class="org.springframework.jms.core.JmsTemplate">
<property name="connectionFactory" ref="jmsFactory"/>
</bean>
<!-- a sample POJO which uses a Spring JmsTemplate -->
<bean id="producer" class="org.apache.activemq.spring.SpringProducer">
<property name="template">
@ -65,7 +71,7 @@
<!-- a sample POJO consumer -->
<bean id="consumer" class="org.apache.activemq.spring.SpringConsumer">
<property name="template" ref="myJmsTemplate"/>
<property name="template" ref="consumerJmsTemplate"/>
<property name="destination" ref="destination"/>
</bean>

View File

@ -42,6 +42,10 @@
</property>
</bean>
<bean id="consumerJmsTemplate" class="org.springframework.jms.core.JmsTemplate">
<property name="connectionFactory" ref="jmsFactory"/>
</bean>
<!-- a sample POJO which uses a Spring JmsTemplate -->
<bean id="producer" class="org.apache.activemq.spring.SpringProducer">
<property name="template">
@ -61,7 +65,7 @@
<!-- a sample POJO consumer -->
<bean id="consumer" class="org.apache.activemq.spring.SpringConsumer">
<property name="template">
<ref bean="myJmsTemplate"></ref>
<ref bean="consumerJmsTemplate"></ref>
</property>
<property name="destination">

View File

@ -72,6 +72,15 @@
</property>
</bean>
<bean id="consumerJmsTemplate" class="org.springframework.jms.core.JmsTemplate">
<property name="pubSubDomain">
<value>true</value>
</property>
<property name="connectionFactory" ref="myConnectionFactory"/>
<property name="defaultDestination">
<ref bean="myDestination"/>
</property>
</bean>
<!-- a sample POJO which uses a Spring JmsTemplate -->
<bean id="producer" class="org.apache.activemq.spring.SpringProducer">
@ -92,7 +101,7 @@
<!-- a sample POJO consumer -->
<bean id="consumer" class="org.apache.activemq.spring.SpringConsumer">
<property name="template">
<ref bean="myJmsTemplate"></ref>
<ref bean="consumerJmsTemplate"></ref>
</property>
<property name="destination">

View File

@ -40,6 +40,13 @@
</property>
</bean>
<bean id="consumerJmsTemplate" class="org.springframework.jms.core.JmsTemplate">
<property name="connectionFactory" ref="jmsFactory"/>
<property name="pubSubDomain">
<value>false</value>
</property>
</bean>
<!-- a sample POJO which uses a Spring JmsTemplate -->
<bean id="producer" class="org.apache.activemq.spring.SpringProducer">
<property name="template">
@ -59,7 +66,7 @@
<!-- a sample POJO consumer -->
<bean id="consumer" class="org.apache.activemq.spring.SpringConsumer">
<property name="template">
<ref bean="myJmsTemplate"></ref>
<ref bean="consumerJmsTemplate"></ref>
</property>
<property name="destination">

View File

@ -37,6 +37,10 @@
</property>
</bean>
<bean id="consumerJmsTemplate" class="org.springframework.jms.core.JmsTemplate">
<property name="connectionFactory" ref="jmsFactory"/>
</bean>
<!-- a sample POJO which uses a Spring JmsTemplate -->
<bean id="producer" class="org.apache.activemq.spring.SpringProducer">
<property name="template">
@ -56,7 +60,7 @@
<!-- a sample POJO consumer -->
<bean id="consumer" class="org.apache.activemq.spring.SpringConsumer">
<property name="template">
<ref bean="myJmsTemplate"></ref>
<ref bean="consumerJmsTemplate"></ref>
</property>
<property name="destination">