Class EndpointRegistry

java.lang.Object
com.github.sonus21.rqueue.core.EndpointRegistry

public final class EndpointRegistry extends Object
Stores all registered queue details

this stores all the queue details mapped from RqueueListener.

  • Method Details

    • get

      public static QueueDetail get(String queueName)
      Get QueueDetail for the given queue. If queue is having priority than it should be called with PriorityUtils.getQueueNameForPriority(String, String).
      Parameters:
      queueName - queue name
      Returns:
      queue detail
      Throws:
      QueueDoesNotExist - this error is thrown when queue is not registered.
      See Also:
    • get

      public static QueueDetail get(String queueName, String priority)
      Get QueueDetail for the given queue, with priority
      Parameters:
      queueName - queue name
      priority - priority of this queue like critical, high
      Returns:
      queue detail
      Throws:
      QueueDoesNotExist - this error is thrown when queue is not registered.
    • register

      public static void register(QueueDetail queueDetail)
    • delete

      public static void delete()
    • getActiveQueues

      public static List<String> getActiveQueues()
    • getActiveQueueDetails

      public static List<QueueDetail> getActiveQueueDetails()
    • getActiveQueueMap

      public static Map<String,QueueDetail> getActiveQueueMap()
    • toStr

      public static String toStr()
    • getActiveQueueCount

      public static int getActiveQueueCount()
    • getRegisteredQueueCount

      public static int getRegisteredQueueCount()