4
我MULE從HornetQ的隊列中讀取和保存對象數據庫的非常簡單的設置:下面JMS騾子最大交還超過
設置:
<jms:connector name="connector.jms" maxRedelivery="1" connectionFactory-ref="hornetQConnectionFactory" doc:name="JMS"
createMultipleTransactedReceivers="true"
numberOfConcurrentTransactedReceivers="100"
acknowledgementMode="AUTO_ACKNOWLEDGE">
<reconnect count="50" frequency="5000"/>
</jms:connector>
<flow name="jmsListenerFlow1" doc:name="jmsListenerFlow1">
<jms:inbound-endpoint queue="adsLogQueue" connector-ref="connector.jms" doc:name="JMS">
<jms:transaction action="ALWAYS_BEGIN"/>
</jms:inbound-endpoint>
<component >
<spring-object bean="logSaver"/>
</component>
</flow>
爲什麼我收到一條消息,該消息已被在maxRedelivery設置爲1時在端點上重新發送了9次?這究竟意味着什麼?
hornetQConnectionFactory:
<bean name="hornetQTransportConfiguration" class="org.hornetq.api.core.TransportConfiguration">
<constructor-arg value="org.hornetq.core.remoting.impl.netty.NettyConnectorFactory"/>
<constructor-arg>
<map>
<entry key="host" value="${jms.host}" />
<entry key="port" value="${jms.port}" />
</map>
</constructor-arg>
</bean>
<bean name="hornetQConnectionFactory" class="org.hornetq.jms.client.HornetQJMSConnectionFactory">
<constructor-arg index="0" value="false"/>
<constructor-arg index="1" ref="hornetQTransportConfiguration"/>
<property name="minLargeMessageSize" value="250000"/>
<property name="cacheLargeMessagesClient" value="false"/>
</bean>
任何幫助將不勝感激!
下面的堆棧跟蹤。
ERROR 2012-10-19 01:04:07,283 [Thread-3013 (HornetQ-client-global-threads-1442093417)]: Message : "Message with id "ID:e6a0b303-1977-11e2-96d4-810571a3fe10" has been redelivered 9 times on endpoint "jms://adsLogQueue", which exceeds the maxRedelivery setting of 1 on the connector "connector.jms". Message payload is of type: HornetQObjectMessage Code : MULE_ERROR--2 Exception stack is: 1. "Message with id "ID:e6a0b303-1977-11e2-96d4-810571a3fe10" has been redelivered 9 times on endpoint "jms://adsLogQueue", which exceeds the maxRedelivery setting of 1 on the connector "connector.jms". Message payload is of type: HornetQObjectMessage (org.mule.transport.jms.redelivery.MessageRedeliveredException) org.mule.transport.jms.redelivery.JmsXRedeliveryHandler:91 (http://www.mulesoft.org/docs/site/current3/apidocs/org/mule/transport/jms/redelivery/MessageRedeliveredException.html) Root Exception stack trace: org.mule.transport.jms.redelivery.MessageRedeliveredException: "Message with id "ID:e6a0b303-1977-11e2-96d4-810571a3fe10" has been redelivered 9 times on endpoint "jms://adsLogQueue", which exceeds the maxRedelivery setting of 1 on the connector "connector.jms". Message payload is of type: HornetQObjectMessage at org.mule.transport.jms.redelivery.JmsXRedeliveryHandler.handleRedelivery(JmsXRedeliveryHandler.java:91) at org.mule.transport.jms.MultiConsumerJmsMessageReceiver$JmsWorker.preProcessMessage(MultiConsumerJmsMessageReceiver.java:418) at org.mule.transport.AbstractReceiverWorker$1$1.process(AbstractReceiverWorker.java:120) + 3 more (set debug level logging or '-Dmule.verbose.exceptions=true' for everything) ********************************************************************************
你可以分享hornetQConnectionFactory配置嗎? – genjosanzo
@genjosanzo補充感謝您檢查 –
您是否有幾個Mule實例連接到同一個隊列? –