diff --git a/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/ipc/FairCallQueue.java b/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/ipc/FairCallQueue.java index 6db9348980..84614a874d 100644 --- a/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/ipc/FairCallQueue.java +++ b/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/ipc/FairCallQueue.java @@ -25,6 +25,7 @@ import java.util.Iterator; import java.util.AbstractQueue; import java.util.HashMap; +import java.util.List; import java.util.concurrent.BlockingQueue; import java.util.concurrent.LinkedBlockingQueue; import java.util.concurrent.Semaphore; @@ -58,8 +59,12 @@ public class FairCallQueue extends AbstractQueue public static final Logger LOG = LoggerFactory.getLogger(FairCallQueue.class); - /* The queues */ - private final ArrayList> queues; + /** + * Save the queue data of multiple priority strategies. + * Usually the number of queue data and priority strategies saved + * is the same. + */ + private final List> queues; /* Track available permits for scheduled objects. All methods that will * mutate a subqueue must acquire or release a permit on the semaphore.