3 Replies Latest reply on Jan 15, 2007 6:57 AM by pander

    Object attributes loosing values



      I am testing out JBOSS Messaging to see if it fits in with the new direction in which we want to take some of our applications and have been extending some of the examples to include the passing Java Objects around onto queues and topics instead of just text.

      I have got 2 processes working with the "testTopic". The first process fires up first and starts listening for messages... the second process starts, fires off a message (Java Object) which the first process receives, sets a timestamp on the object using the ojects setter method and then fires the message back to onto the "testTopic" which the second process finally picks up and checks. However, despite verifying that the value has been set before sending the message back, the second process thinks that the timestamp field is null.

      Am I doing something fundamentally wrong or are objects not writable or something?


        • 1. Re: Object attributes loosing values

          Please post your java object code.

          Also what versions are you running, etc etc?

          • 2. Re: Object attributes loosing values

            Also please post your code that sends and receives the objects and checks the timestamp.

            • 3. Re: Object attributes loosing values

              Hi Guys,

              Sorry, I've just found out what the issue was.... my own stupid mistake!

              The second process that sends the first message was actually also receiving it back before the first process had set the timestamp, so naturally it would be null. It was the fact that the second process was reporting to have received the message back before the first process had updated the timestamp that gave it away.

              Apologies, Paul.