Interface Queue

All Known Implementing Classes:
QueueImpl

public interface Queue
Interface for defining OCI Queue module.
  • Method Summary

    Modifier and Type
    Method
    Description
    createQueue(String queueName, String compartmentId, Integer deadLetterQueueDeliveryCount, Integer retentionInSeconds)
    Creates a queue in a compartment.
    com.oracle.bmc.queue.responses.DeleteMessageResponse
    deleteMessage(String queueId, String messageReceipt)
    Delete the message by the receipt from a queue
    com.oracle.bmc.queue.responses.DeleteQueueResponse
    Delete the queue by id.
    com.oracle.bmc.queue.responses.GetMessagesResponse
    getMessages(String queueId, Integer visibilityInSeconds, Integer timeoutInSeconds, Integer limit)
    Get/consume messages from a queue.
    com.oracle.bmc.queue.responses.GetQueueResponse
    getQueue(String queueId)
    Get the queue resource.
    com.oracle.bmc.queue.QueueAdminClient
    Direct instance of OCI Java SDK QueueAdminClient.
    com.oracle.bmc.queue.QueueClient
    Direct instance of OCI Java SDK QueueClient.
    com.oracle.bmc.queue.responses.ListQueuesResponse
    listQueues(String queueName, String compartmentId)
    List the queues by name and/or in a compartment.
    com.oracle.bmc.queue.responses.PutMessagesResponse
    putMessages(String queueId, String[] messages)
    Put messages into a queue.
    com.oracle.bmc.queue.responses.UpdateMessagesResponse
    updateMessages(String queueId, String[] messageReceipts, Integer visibilityInSeconds)
    Update the messages by their receipt in a queue.
  • Method Details

    • getQueueAdminClient

      com.oracle.bmc.queue.QueueAdminClient getQueueAdminClient()
      Direct instance of OCI Java SDK QueueAdminClient.
      Returns:
      QueueAdminClient
    • getQueueClient

      com.oracle.bmc.queue.QueueClient getQueueClient()
      Direct instance of OCI Java SDK QueueClient.
      Returns:
      QueueClient
    • putMessages

      com.oracle.bmc.queue.responses.PutMessagesResponse putMessages(String queueId, String[] messages)
      Put messages into a queue.
      Parameters:
      queueId - OCID of the queue
      messages - list of messages
      Returns:
      PutMessagesResponse
    • getMessages

      com.oracle.bmc.queue.responses.GetMessagesResponse getMessages(String queueId, Integer visibilityInSeconds, Integer timeoutInSeconds, Integer limit)
      Get/consume messages from a queue.
      Parameters:
      queueId - OCID of the queue
      visibilityInSeconds - Messages will be hidden and won't be consumable by other consumers for this time
      timeoutInSeconds - Timeout for the request
      limit - The maximum number of messages returned
      Returns:
      GetMessagesResponse
    • updateMessages

      com.oracle.bmc.queue.responses.UpdateMessagesResponse updateMessages(String queueId, String[] messageReceipts, Integer visibilityInSeconds)
      Update the messages by their receipt in a queue.
      Parameters:
      queueId - OCID of the queue
      messageReceipts - List of message receipts to be updated
      visibilityInSeconds - Messages will be hidden and won't be consumable by other consumers for this time
      Returns:
      UpdateMessagesResponse
    • deleteMessage

      com.oracle.bmc.queue.responses.DeleteMessageResponse deleteMessage(String queueId, String messageReceipt)
      Delete the message by the receipt from a queue
      Parameters:
      queueId - OCID of the queue
      messageReceipt - The receipt of the message to be deleted
      Returns:
      DeleteMessageResponse
    • createQueue

      String createQueue(String queueName, String compartmentId, Integer deadLetterQueueDeliveryCount, Integer retentionInSeconds)
      Creates a queue in a compartment.
      Parameters:
      queueName - Name of the queue to be created
      compartmentId - Compartment OCID where the Queue needs to be created
      deadLetterQueueDeliveryCount - The number of times a message is delivered before its moved to the dead letter queue
      retentionInSeconds - The time a message remains in the queue before its deleted by the service if it is not deleted by a consumer
      Returns:
      String OCID of the queue
    • getQueue

      com.oracle.bmc.queue.responses.GetQueueResponse getQueue(String queueId)
      Get the queue resource.
      Parameters:
      queueId - OCID of the queue
      Returns:
      GetQueueResponse
    • listQueues

      com.oracle.bmc.queue.responses.ListQueuesResponse listQueues(String queueName, String compartmentId)
      List the queues by name and/or in a compartment.
      Parameters:
      queueName - Name of the queue to list them
      compartmentId - Compartment OCID where to list the Queues
      Returns:
      ListQueuesResponse
    • deleteQueue

      com.oracle.bmc.queue.responses.DeleteQueueResponse deleteQueue(String queueId)
      Delete the queue by id.
      Parameters:
      queueId - OCID of the queue
      Returns:
      DeleteQueueResponse