3 Replies Latest reply on Jan 8, 2010 9:32 AM by Clebert Suconic

    Losing packets on blocked calls

    Clebert Suconic Master

      Just an update...


      I have been investigating why MultiThreadRandomReattachTestBase would eventually loose packets.


      So far what I have discovered is that the channel will be eventually null on RemotingConnectionimpl, making the call to be ignored.



      I can see that by adding some debug at RemotingConnectionimpl::doBufferReceived.


      I'm now trying to figure out why the channel would be null.


           synchronized (transferLock)


               if (channel != null)

                  if (packet instanceof SessionDeleteQueueMessage)
                     SessionDeleteQueueMessage deleteQueue = (SessionDeleteQueueMessage)packet;
                     log.debug("RemotingConnection didn't have a channel to process SessionDeleteQueueMessage::" + deleteQueue.getQueueName());

        • 1. Re: Losing packets on blocked calls
          Clebert Suconic Master

          I have created a JIRA: https://jira.jboss.org/jira/browse/HORNETQ-261



          From what I have seen, it's not just blocked calls that might be lost. For some reason the session could be removed from the correct channel at HornetQServerimpl::createSession over these operations:



                ServerSession currentSession = sessions.remove(name);

                if (currentSession != null)
                   // This session may well be on a different connection and different channel id, so we must get rid
                   // of it and create another


          Maybe (just a guess) this is happening because of replay over createSessions. I would need more time to investigate.


          I'm working at the AS6 integration now.. so I will come back working at this later. (Unless someone else takes over this)

          • 2. Re: Losing packets on blocked calls
            Tim Fox Master

            Hmm, I'm trying to remember why I added that code.


            Sometime in the past there *was* a reason, although I'm not sure it's still needed, and I can't remember what the reason was


            I will have a think about it

            • 3. Re: Losing packets on blocked calls
              Clebert Suconic Master

              I believe this issue will be fixed If that code can be removed.


              I've tried it without it and the test passed up to 500 iterations. (I would need to try more just to be safe).