org.apache.synapse.commons.executors

## Interface NextQueueAlgorithm<E>

- Type Parameters:
    `E` -
  All Known Implementing Classes:
    PRRNextQueueAlgorithm

      public interface NextQueueAlgorithm<E>

  This interface abstracts the algorithm for determining the next internal queue for picking up the message. This class is created once and initialized. This class should capture any runtime information about the queues since the MultiPriorityBlockingQueue doesn't hold any runtime state information about the queues.

- - ### Method Summary

    All Methods Instance Methods Abstract Methods
    Modifier and Type | Method and Description
    --- | ---
    `InternalQueue<E>` | `getNextQueue()` Should return a queue based on some selection criteria and current state of the queues.
    `void` | `init(List<InternalQueue<E>> queues)` Initialized with the queues sorted according to the priority.

- - ### Method Detail

    - #### init

          void init(List<InternalQueue<E>> queues)

      Initialized with the queues sorted according to the priority.
      Parameters:
        `queues` - list of queues

    - #### getNextQueue

          InternalQueue<E> getNextQueue()

      Should return a queue based on some selection criteria and current state of the queues.
      Returns:
        the queue

Copyright © 2005–2019 Apache Software Foundation. All rights reserved.