activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Andres Rangel" <andr...@corp.moniker.com>
Subject RE: Redelivering messages inconsistency
Date Tue, 30 Sep 2008 19:29:25 GMT
I found the issue.
The time of the client machine was off by one hour to the server(one
running the jms server).
When I updated the ttl to a very big number (50 hrs), the messages were
picked up correctly.

Why would the jms client set a timestamp local to the client and not
local to the jms server??

Is this a bug?


--
Andres Rangel
Sw Engineer
Moniker.com



-----Original Message-----
From: Andres Rangel [mailto:andresr@corp.moniker.com] 
Sent: Friday, September 19, 2008 12:10 PM
To: users@activemq.apache.org
Subject: RE: Redelivering messages inconsistency

Hi rob, thanks for the reply.
>>. I'm not certain if these are application properties (yours) or
ActiveMQ ones (ours) without looking  at an example. Are you using
message listeners/selectors?
I am using message listeners. 
On the  onMessage(Message message) method I just:
	validateMessage(message);
	TextMessage mesg = (TextMessage) message;
	... Obtain where to send
	Destination dest = getNewDestination(mesg.getText());
	sender.send(dest,mesg,DeliveryMode.NON_PERSISTENT,
javax.jms.Message.DEFAULT_PRIORITY, 600000);

My work around was to clone the message and send the cloned msg instead.

>> but if you submit a small test case - we can see  if we can find the
route cause, too.
I can't replicate it now. But if I am able to replicate it, then I will
post a small test case to learn wath is the problems


Thanks again


--
Andres Rangel
Sw Engineer
Moniker.com




-----Original Message-----
From: Rob Davies [mailto:rajdavies@gmail.com] 
Sent: Thursday, September 18, 2008 1:13 AM
To: users@activemq.apache.org
Subject: Re: Redelivering messages inconsistency

Hi Andres,

what you are experiencing is a classic 'timing issue' - it seems that  
there are some properties on the original message that are being  
overwritten when you send it again. I'm not certain if these are  
application properties (yours) or ActiveMQ ones (ours) without looking  
at an example. There is definitely a problem there - are you using  
message listeners/selectors?

I would suggest you keep doing the copy of the message for your  
production system - but if you submit a small test case - we can see  
if we can find the route cause, too.


cheers,

Rob

Rob Davies
http://rajdavies.blogspot.com/





On 17 Sep 2008, at 20:41, Andres Rangel wrote:

> Hi We have been working on with ActiveMQ on a custom content based
> router.
>
> We first try to use Camel, but since the routes changed very often  
> (the
> routing instructions) then we decided to implement it using standard  
> jms
> code ,and deploying it in an embedded broker.
>
>
>
>
>
> The Content Based Router does the following: reads from a channel, and
> depending on the message it redelivers it to another channel.
>
>
>
> Everything was working fine in my machine, and when we deployed to a
> staging server, we encountered some problems.
>
> The problem is in essence the following: the message gets delivered to
> the corresponding channel by the content based Router, but our client
> applications (the ones listening to these channels) cannot read those
> messages, even though we can see the messages in the queues (using the
> admin web console).
>
>
>
> After much reading, I decided to "clone the message" that is copy the
> incoming message in the content router, and send the new message.
>
> And somehow it resolved the problem.
>
>
>
> Today, I rolled back the code, to replicate the issue and could not
> replicated. Strangely the application worked and the clients were
> reading the messages.
>
>
>
> I don't know what is happening.
>
>
>
> I am really concerned that this problem may occur again in production
> and we will not be able to correct it, since we have not identified  
> the
> source of the problem.
>
>
>
>
>
> Is there a problem for ActiveMQ if I redeliver a message? Or should I
> always clone it and send it again?
>
>
>
> Thanks,
>
>
>
>
>
>
>
>
>
> --
>
> Andres Rangel
>
> Sw Engineer
>
> Moniker.com
>
>
>


Mime
View raw message