activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Christopher G. Stach II" <...@ldsys.net>
Subject Re: DefaultMessageListenerContainer + not remove messages until processed
Date Thu, 05 Apr 2007 14:51:26 GMT
Garner, Shawn wrote:
> This article told me in my case I should use Jencks since I'm using JMS
> Template in a non-EJB container.
> 
> http://activemq.apache.org/jmstemplate-gotchas.html
> 
> 
> Shawn
> 
> -----Original Message-----
> From: James Strachan [mailto:james.strachan@gmail.com] 
> Sent: Wednesday, April 04, 2007 11:19 AM
> To: users@activemq.apache.org
> Subject: Re: DefaultMessageListenerContainer + not remove messages until
> processed
> 
> On 4/4/07, Garner, Shawn <shawn.garner@vangent.com> wrote:
>> I put a org.springframework.jms.connection.JmsTransactionManager on
> the
>> DefaultMessageListenerContainer but all this does is roll back any
>> changes I made after consuming the message.
>>
>> I am also using the org.jencks.factory.TransactionManagerFactoryBean
> and
>> org.jencks.factory.ConnectionManagerFactoryBean since I'm in Tomcat
>> without any EJB layer.
>>
>> It does not put the message back into the queue like I want.
>>
>> How do you enable client-acknowledge mode?
> 
> See the spring javadoc on how to enable ack modes or transactional
> consumption.
> 
> http://static.springframework.org/spring/docs/2.0.x/api/org/springframew
> ork/jms/listener/DefaultMessageListenerContainer.html
> 
> also note that the Spring listener containers don't use JCA so there's
> no real point using Jencks; just use the spring transaction manager
> abstraction
> 

Are you sure that you've even started a transaction before attempting to
consume the message and that an explicit rollback doesn't keep the the
message in the queue?

-- 
Christopher G. Stach II


Mime
View raw message