getPropertyNames on ActiveMQMessage supported?

View: New views
2 Messages — Rating Filter:   Alert me  

getPropertyNames on ActiveMQMessage supported?

by Robert Nicholson-3 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

So I'm doing the following in some JMS code

Enumeration headers = message.getPropertyNames();
         if (!headers.hasMoreElements()) {
             return;
         }

However an Enumeration that is empty. Is that expected?

I'm replaying messages from a Hermes Message store into an ActiveMQ  
Queue but it doesn't look like they are getting any properties set.

timestamp on the message object does have a valid timestamp.

I'm using 5.3-SNAPSHOT but

I see this message earlier

http://osdir.com/ml/java.geronimo.user/2006-03/msg00051.html

Re: getPropertyNames on ActiveMQMessage supported?

by Dejan Bosanac :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

You can try to copy() the message before resending it and see if that helps.

Cheers
--
Dejan Bosanac - http://twitter.com/dejanb

Open Source Integration - http://fusesource.com/
ActiveMQ in Action - http://www.manning.com/snyder/
Blog - http://www.nighttale.net


On Sat, Nov 7, 2009 at 5:48 AM, Robert Nicholson <robert.nicholson@...
> wrote:

> So I'm doing the following in some JMS code
>
> Enumeration headers = message.getPropertyNames();
>        if (!headers.hasMoreElements()) {
>            return;
>        }
>
> However an Enumeration that is empty. Is that expected?
>
> I'm replaying messages from a Hermes Message store into an ActiveMQ Queue
> but it doesn't look like they are getting any properties set.
>
> timestamp on the message object does have a valid timestamp.
>
> I'm using 5.3-SNAPSHOT but
>
> I see this message earlier
>
> http://osdir.com/ml/java.geronimo.user/2006-03/msg00051.html
>
Dejan Bosanac

Open Source Integration - http://fusesource.com/
ActiveMQ in Action - http://www.manning.com/snyder/
Blog - http://www.nighttale.net