1 Reply Latest reply on Jul 10, 2003 6:16 PM by nphelps

    JMS Messages

    nmartins

      hi,

      I would like to know if it is possible to modify a jms message object, if this message is not acknowledge?

      Reguards,
      Nuno Martins

        • 1. Re: JMS Messages
          nphelps

          Per the spec. you can reuse message objects on send (i.e. you can send a message object, modify fields and send the same message object again). The JMS provider treats these as completely distinct messages and your changes will not affect the previously sent messages. On the receiving end, both the body of the message and the properties are marked as read only when they are received. However, you can call clearBody/clearProperties to reset the state of the body/properties of a received message and you can then modify them. For more information, see section 3.10 of the JMS specification.