Interface MessageDispatchChannel

All Known Implementing Classes:
FifoMessageDispatchChannel, SimplePriorityMessageDispatchChannel

public interface MessageDispatchChannel
  • Method Details

    • enqueue

      void enqueue(MessageDispatch message)
    • enqueueFirst

      void enqueueFirst(MessageDispatch message)
    • isEmpty

      boolean isEmpty()
    • dequeue

      MessageDispatch dequeue(long timeout) throws InterruptedException
      Used to get an enqueued message. The amount of time this method blocks is based on the timeout value. - if timeout==-1 then it blocks until a message is received. - if timeout==0 then it it tries to not block at all, it returns a message if it is available - if timeout>0 then it blocks up to timeout amount of time. Expired messages will consumed by this method.
      Returns:
      null if we timeout or if the consumer is closed.
      Throws:
      jakarta.jms.JMSException
      InterruptedException
    • dequeueNoWait

      MessageDispatch dequeueNoWait()
    • peek

    • start

      void start()
    • stop

      void stop()
    • close

      void close()
    • clear

      void clear()
    • isClosed

      boolean isClosed()
    • size

      int size()
    • getMutex

      Object getMutex()
    • isRunning

      boolean isRunning()
    • removeAll

      List<MessageDispatch> removeAll()