Package dev.galasa.mq

Interface IMessageQueue


public interface IMessageQueue
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    Clears the queue by consuming messages until queue is empty messages consumed are not archived regardless of the '@queue' annotation
    javax.jms.Message
    Retrieves the first message from the queue, waiting until a message is ready
    javax.jms.Message
    getMessage(long timeout)
    Retrieves the first message from the queue, waiting for the timeout
    javax.jms.Message
    Retrieves the first message from the queue returning immediately if no message is available
    void
    sendMessage(javax.jms.Message... messages)
    puts the provided messages onto the queue
  • Method Details

    • sendMessage

      void sendMessage(javax.jms.Message... messages)
      puts the provided messages onto the queue
      Parameters:
      messages - the set of messages to send
    • getMessage

      javax.jms.Message getMessage()
      Retrieves the first message from the queue, waiting until a message is ready
      Returns:
      the message from the queue
    • getMessage

      javax.jms.Message getMessage(long timeout)
      Retrieves the first message from the queue, waiting for the timeout
      Parameters:
      timeout - - long timeout in milliseconds
      Returns:
      the message - or null if no message is available before timeout
    • getMessageNoWait

      javax.jms.Message getMessageNoWait()
      Retrieves the first message from the queue returning immediately if no message is available
      Returns:
      the message from the queue or null
    • clearQueue

      void clearQueue()
      Clears the queue by consuming messages until queue is empty messages consumed are not archived regardless of the '@queue' annotation