当我将solace用作消息传递服务器时,我遇到了此异常。
MessageListenerContainer - Setup of JMS message listener invoker failed for destination 'XXX.QUE' - trying to recover. Cause: Transacted sessions or XA sessions are not supported with direct transport
我使用SESSION_TRANSACTED
手动进行交易
这是一些配置。
<bean id="solacelay2ConnF" class="com.solacesystems.jms.SolJmsUtility" factory-method="createConnectionFactory">
<property name="host" value="${solace.jms.url}"></property>
<property name="username" value="${solace.jms.username}"></property>
<property name="password" value="${solace.jms.password}"></property>
<property name="VPN" value="${solace.jms.vpn}"></property>
</bean>
<bean id="solace"
class="org.springframework.jms.connection.CachingConnectionFactory">
<property name="targetConnectionFactory" ref="solacelay2ConnF" />
<property name="sessionCacheSize" value="30" />
</bean>
<bean id="JMSC" class="org.apache.camel.component.jms.JmsComponent">
<property name="connectionFactory" ref="solace" />
</bean>
<camelContext id="JMS_MCI" xmlns="http://camel.apache.org/schema/spring">
<endpoint id="commonJmsMciInQue" uri="JMSC:queue:XXX.QUE">
<property key="testConnectionOnStartup" value="true" />
<property key="disableReplyTo" value="true" />
<property key="concurrentConsumers" value="10" />
<property key="acknowledgementModeName" value="SESSION_TRANSACTED" />
</endpoint>
<route id="JMS_MCI_LISTENER">
<from ref="commonJmsMciInQue" />
<from uri="direct:mciMsg" />
<process ref="mciMsgListener" />
</route>
</camelContext>
有人可以帮忙吗?
非常感谢!〜
答案 0 :(得分:1)
可能是在Solace PubSub +消息代理方上名为solacelay2ConnF的连接工厂对象中启用了“直接传输”。启用直接传输模式后,客户端将无法创建事务处理的会话。