3 Replies Latest reply on Jan 11, 2010 10:48 AM by clebert.suconic

    OperationContext ordering

    timfox

      I spotted this comment in HornetQServerImpl::

       

      // The executor on the OperationContext here has to be the same as the session, or we would have ordering issues
      // on messages

       

      Can you explain what ordering issues would occur, and what specific operation on the session it is referring to?

        • 1. Re: OperationContext ordering
          clebert.suconic

          Say you send persistent and non-persistent messages on the same session.

           

          When you send a non-persistent message, it needs to wait the deliver of the persistent message first or else it would be sent out of order.

           

          If I don't reuse the OperationContext between calls, the send of the non-persistent would not wait the previous message.

           

           

          You will probably remember that when you read this forum post:

           

           

          http://community.jboss.org/thread/18992?tstart=60

          • 2. Re: OperationContext ordering
            timfox

            I understand that, but that wasn't the question

             

            The question is why is executor used there the same as the session one.

            • 3. Re: OperationContext ordering
              clebert.suconic
              (09:48:52 AM) clebert: jbossfox: I actually confused the use of the SessionExecutor.. that's moot then...
              (09:48:52 AM) clebert: I thought I would eventually use it in places like...
              (09:49:02 AM) clebert: if (context.pending)
              (09:49:02 AM) clebert: ... do something with the executor...
              (09:49:09 AM) clebert: so.. that's moot now.. you can just ignore that comment