code: public int getMinSlots(String pool, TaskType taskType) {
      Map<String, Integer> allocationMap = (taskType == TaskType.MAP ?
          mapAllocs : reduceAllocs);
      Integer alloc = allocationMap.get(pool);
      return (alloc == null ? 0 : alloc);
    }
docs: Get the allocation for a particular pool