I want to switch the connection to another message broker during runtime.
<bean id="qpidConnectionFactory" class="org.apache.qpid.client.AMQConnectionFactory">
<constructor-arg name="url" ref="connectionURL" />
</bean>
<bean id="connectionFactory" class="org.springframework.jms.connection.CachingConnectionFactory">
<property name="targetConnectionFactory" ref="qpidConnectionFactory" />
<property name="sessionCacheSize" value="10" />
</bean>
How can I do this? Maybe with scopes? And what is about services, transaction managers or message listener which using this factory?
<bean id="transactionManager" class="org.springframework.jms.connection.JmsTransactionManager">
<property name="connectionFactory" ref="connectionFactory" />
</bean>
Aucun commentaire:
Enregistrer un commentaire