Hi Also use the specialized AMQ component over generic JMS as documented here http://camel.apache.org/activemq.html
On Sat, Feb 27, 2010 at 2:52 PM, moacsjr <[email protected]> wrote: > > This are the configurations in my camel-contex.xml > > <camelContext id="camel" > xmlns="http://activemq.apache.org/camel/schema/spring"> > <package>com.tc.recarga.eai</package> > </camelContext> > > <!-- Activemq processor component configuration --> > <bean id="activemq" > class="org.apache.camel.component.jms.JmsComponent"> > <property name="connectionFactory" ref="jmsFactory" /> > </bean> > > <amq:broker useJmx="false"> > <amq:persistenceAdapter> > <amq:jdbcPersistenceAdapter dataSource="#camel-ds" /> > </amq:persistenceAdapter> > <amq:transportConnectors> > <amq:transportConnector uri="tcp://localhost:61636" /> > </amq:transportConnectors> > </amq:broker> > > <amq:connectionFactory id="jmsFactory" brokerURL="vm://localhost" /> > > > My Apis: Spring-2.5.1, camel-1.5.0 and activemq-5.2.0. > > Will try with spring-2.5.6, camel-1.6.2, activemq-5.3.0. > > > > willem.jiang wrote: >> >> How did you configure the jms component? >> It looks like the JMS connection can't reconnect if the Transport >> disposed exception is thrown. >> >> Willem >> >> moacsjr wrote: >>> Hello everybody, >>> >>> I've a route that process messages by using a processor. I've noticed >>> that >>> when the system throws the exception "javax.jms.JMSException: Transport >>> disposed", my route stops the processing of the messages in the queue, >>> and >>> new messages are not being consumed. >>> >>> this is my route: >>> >>> from(uriActivationQueueDistribuidor).process(new AtivarPinProcessor()); >>> >>> In the processor, the exception is throw when we tried to pass the >>> Exchange >>> to anothe endpoint, in the code:producer.process(newExchange). >>> >>> private void sendMessageFromExchange(Exchange exchange, >>> Producer<Exchange> >>> producer) throws Exception { >>> Exchange newExchange = producer.createExchange(); >>> newExchange.getIn().setHeaders(exchange.getIn().getHeaders()); >>> newExchange.getIn().setBody(exchange.getIn().getBody()); >>> producer.process(newExchange); >>> >>> } >>> >>> the full stacktrace: >>> >>> 02...@08:40:08,740 ERROR (DefaultMessageListenerContainer-1385434) - >>> Erro inesperado: Uncategorized exception occured during JMS processing; >>> nested exception is javax.jms.JMSException: Transport disposed.; nested >>> exception is org.apache.activemq.transport.TransportDisposedIOException: >>> Transport disposed. >>> org.springframework.jms.UncategorizedJmsException: Uncategorized >>> exception >>> occured during JMS processing; nested exception is >>> javax.jms.JMSException: >>> Transport disposed.; nested exception is >>> org.apache.activemq.transport.TransportDisposedIOException: Transport >>> disposed. >>> at >>> org.springframework.jms.support.JmsUtils.convertJmsAccessException(JmsUtils.java:289) >>> at >>> org.springframework.jms.support.JmsAccessor.convertJmsAccessException(JmsAccessor.java:172) >>> at >>> org.springframework.jms.core.JmsTemplate.execute(JmsTemplate.java:450) >>> at >>> org.springframework.jms.core.JmsTemplate.send(JmsTemplate.java:523) >>> at >>> org.apache.camel.component.jms.JmsProducer.process(JmsProducer.java:227) >>> at >>> com.tc.recarga.eai.rota.RotaAtivadorPins.sendMessageFromExchange(RotaAtivadorPins.java:513) >>> at >>> com.tc.recarga.eai.rota.RotaAtivadorPins.access$600(RotaAtivadorPins.java:31) >>> at >>> com.tc.recarga.eai.rota.RotaAtivadorPins$AtivarPinProcessor.process(RotaAtivadorPins.java:438) >>> at >>> org.apache.camel.management.InstrumentationProcessor.process(InstrumentationProcessor.java:75) >>> at >>> org.apache.camel.processor.DeadLetterChannel.process(DeadLetterChannel.java:172) >>> at >>> org.apache.camel.processor.DeadLetterChannel.process(DeadLetterChannel.java:93) >>> at >>> org.apache.camel.management.InstrumentationProcessor.process(InstrumentationProcessor.java:63) >>> at >>> org.apache.camel.processor.UnitOfWorkProcessor.process(UnitOfWorkProcessor.java:47) >>> at >>> org.apache.camel.util.AsyncProcessorHelper.process(AsyncProcessorHelper.java:41) >>> at >>> org.apache.camel.processor.DelegateAsyncProcessor.process(DelegateAsyncProcessor.java:66) >>> at >>> org.apache.camel.component.jms.EndpointMessageListener.onMessage(EndpointMessageListener.java:72) >>> at >>> org.springframework.jms.listener.AbstractMessageListenerContainer.doInvokeListener(AbstractMessageListenerContainer.java:531) >>> at >>> org.springframework.jms.listener.AbstractMessageListenerContainer.invokeListener(AbstractMessageListenerContainer.java:466) >>> at >>> org.springframework.jms.listener.AbstractMessageListenerContainer.doExecuteListener(AbstractMessageListenerContainer.java:435) >>> at >>> org.springframework.jms.listener.AbstractPollingMessageListenerContainer.doReceiveAndExecute(AbstractPollingMessageListenerContainer.java:316) >>> at >>> org.springframework.jms.listener.AbstractPollingMessageListenerContainer.receiveAndExecute(AbstractPollingMessageListenerContainer.java:255) >>> at >>> org.springframework.jms.listener.DefaultMessageListenerContainer$AsyncMessageListenerInvoker.invokeListener(DefaultMessageListenerContainer.java:887) >>> >>> >>> Camel: 1.5.0 >>> ActiveMQ: 5.2.0 >>> >> >> >> > > -- > View this message in context: > http://old.nabble.com/javax.jms.JMSException%3A-Transport-disposed-tp27714261p27728115.html > Sent from the Camel - Users (activemq) mailing list archive at Nabble.com. > > -- Claus Ibsen Apache Camel Committer Author of Camel in Action: http://www.manning.com/ibsen/ Open Source Integration: http://fusesource.com Blog: http://davsclaus.blogspot.com/ Twitter: http://twitter.com/davsclaus
