6 Replies Latest reply: May 22, 2012 9:53 PM by Hugh Bragg RSS

    Producer commit blocked

    Hugh Bragg Newbie

      Hi,

       

      I've been using auto-acknowledge for my producer up until now. I'm looking for some ways to increase throughput.

      So I changed my producer to send messages to a session which is transactional. After sending about 500 messages, I then commit.

      What I found was that all the producers are blocked in the commit process.

      I increased jms address space:

      <page-size-bytes>20971520</page-size-bytes>

      <max-size-bytes>167772160</max-size-bytes>

       

      That didn't change anythign so I increased the window size

      <producer-window-size>999999999</producer-window-size>

       

      Still no change.

      There are no exceptions and the producer is permanently blocked:

      Stack trace:

      sun.misc.Unsafe.park(Native Method)

      java.util.concurrent.locks.LockSupport.parkNanos(LockSupport.java:226)

      java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.await(AbstractQueuedSynchronizer.java:2176)

      org.hornetq.core.protocol.core.impl.ChannelImpl.sendBlocking(ChannelImpl.java:256)

         - locked java.lang.Object@316fcf58

      org.hornetq.core.client.impl.ClientSessionImpl.commit(ClientSessionImpl.java:528)

      org.hornetq.core.client.impl.DelegatingSession.commit(DelegatingSession.java:157)

      org.hornetq.jms.client.HornetQSession.commit(HornetQSession.java:234)

       

      When I <ctrl>-c the program generating an interrupt exception, oddly the current batch of messages waiting for commit are sent and then the program exits.

       

      The code I use is almost identical to the JMS Transactional Session Example except I'm using

      HornetQJMSClient.createQueue

      HornetQConnectionFactory hqcf = HornetQJMSClient.createConnectionFactoryWithoutHA(JMSFactoryType.QUEUE_CF, transportConfiguration);

       

       

      Could anyone please offer any expanation or even a guess as to what might be wrong?

       

      Thanks