Class AMQConsumer


  • public class AMQConsumer
    extends Object
    • Constructor Detail

      • AMQConsumer

        public AMQConsumer​(AMQSession amqSession,
                           org.apache.activemq.command.ActiveMQDestination d,
                           org.apache.activemq.command.ConsumerInfo info,
                           ScheduledExecutorService scheduledPool,
                           boolean internalAddress)
    • Method Detail

      • getId

        public org.apache.activemq.command.ConsumerId getId()
      • acquireCredit

        public void acquireCredit​(int n,
                                  boolean delivered)
      • handleDeliverNullDispatch

        public void handleDeliverNullDispatch()
      • acknowledge

        public void acknowledge​(org.apache.activemq.command.MessageAck ack)
                         throws Exception
        The acknowledgement in openwire is done based on intervals. We will iterate through the list of delivering messages at ServerConsumer.scanDeliveringReferences(boolean, Function, Function) and add those to the Transaction. Notice that we will start a new transaction on the cases where there is no transaction.
        Throws:
        Exception
      • browseFinished

        public void browseFinished()
      • getInfo

        public org.apache.activemq.command.ConsumerInfo getInfo()
      • hasCredits

        public boolean hasCredits()
      • processMessagePull

        public void processMessagePull​(org.apache.activemq.command.MessagePull messagePull)
                                throws Exception
        Throws:
        Exception
      • getOpenwireDestination

        public org.apache.activemq.command.ActiveMQDestination getOpenwireDestination()
      • setPrefetchSize

        public void setPrefetchSize​(int prefetchSize)
      • updateDeliveryCountAfterCancel

        public boolean updateDeliveryCountAfterCancel​(MessageReference ref)
      • removeRolledback

        public void removeRolledback​(MessageReference messageReference)
      • addRolledback

        public void addRolledback​(MessageReference messageReference)