camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Magnus Heino" <mag...@filur.org>
Subject Re: Bug?
Date Fri, 08 Feb 2008 14:17:36 GMT
>
> > It seems as if I am missing something fundamental here? I feel the smell
> of
> > a new user rtfm problem, but where is it? :)
>
> :) No I think there maybe some MessageListenerContainer configuration
> gremlin you're hitting (though its really bizarre that things work
> fine for JMS transactions, but not when switching to XA!)
>
> Camel tries its best to setup the various Spring objects right for you
> without you having to set zillions of properties up; but maybe there's
> some gremlin in there that needs fixing...
>
>
> > How is my JmsComponent looked up by camel?
>
> So the CamelContext looks up in the Spring AppContext to see if
> there's an endpoint for the URI, if not it takes the URI scheme (e.g.
> jms) and looks up if there's a Component registered for that name and
> uses that component to create the endpoint.


So my JmsComponent needs to be named jms? My was unnamed i.e. I didn't
provide a spring id.

If I give my JmsComponent instance in spring the id "jms", I get these
errors; Notice the Message received: 'demo'  in the beginning, messages are
consumed now, they are removed from ems too, even when I shutdown JBoss.

15:06:24,812 INFO  [Server] JBoss (MX MicroKernel) [4.2.2.GA (build:
SVNTag=JBoss_4_2_2_GA date=200710221139)] Started in 12s:408ms
15:06:24,859 INFO  [STDOUT] 2008-02-08 15:06:24,859
[DefaultMessageListenerContainer-1] INFO  Message received: 'demo' at
se.lantmateriet.origo.service.internal.UpdateServiceImpl.handleMessage(
UpdateServiceImpl.java:34)
15:06:24,890 INFO  [STDOUT] 2008-02-08 15:06:24,890
[DefaultMessageListenerContainer-2] ERROR Setup of JMS message listener
invoker failed - trying to recover at
org.springframework.jms.listener.DefaultMessageListenerContainer.handleListenerSetupFailure
(DefaultMessageListenerContainer.java:671)
javax.jms.IllegalStateException: The connection is closed
    at org.jboss.resource.adapter.jms.JmsSessionFactoryImpl.checkClosed(
JmsSessionFactoryImpl.java:413)
    at org.jboss.resource.adapter.jms.JmsSessionFactoryImpl.createSession(
JmsSessionFactoryImpl.java:368)
    at org.springframework.jms.support.JmsAccessor.createSession(
JmsAccessor.java:200)
    at
org.springframework.jms.listener.AbstractPollingMessageListenerContainer.access$200
(AbstractPollingMessageListenerContainer.java:76)
    at
org.springframework.jms.listener.AbstractPollingMessageListenerContainer$MessageListenerContainerResourceFactory.createSession
(AbstractPollingMessageListenerContainer.java:477)
    at
org.springframework.jms.connection.ConnectionFactoryUtils.doGetTransactionalSession
(ConnectionFactoryUtils.java:282)
    at
org.springframework.jms.listener.AbstractPollingMessageListenerContainer.doReceiveAndExecute
(AbstractPollingMessageListenerContainer.java:279)
    at
org.springframework.jms.listener.AbstractPollingMessageListenerContainer.receiveAndExecute
(AbstractPollingMessageListenerContainer.java:235)
    at
org.springframework.jms.listener.DefaultMessageListenerContainer$AsyncMessageListenerInvoker.invokeListener
(DefaultMessageListenerContainer.java:887)
    at
org.springframework.jms.listener.DefaultMessageListenerContainer$AsyncMessageListenerInvoker.run
(DefaultMessageListenerContainer.java:822)
    at java.lang.Thread.run(Thread.java:595)
15:06:24,906 INFO  [STDOUT] 2008-02-08 15:06:24,906
[DefaultMessageListenerContainer-2] INFO  Successfully refreshed JMS
Connection at
org.springframework.jms.listener.DefaultMessageListenerContainer.refreshConnectionUntilSuccessful
(DefaultMessageListenerContainer.java:712)

If I add <property name="cacheLevelName" value="CACHE_NONE" />, things seems
to work!!!!! :-)


> Did any of that help? :)


I guess so, but I don't understand if this is expected behaviour, or a bug?
:)

Thanks!!

/Magnus

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message