storm-server/src/main/java/org/apache/storm/scheduler/resource/strategies/scheduling/sorter/NodeSorterHostProximity.java [669:684]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    public Iterable<ObjectResourcesItem> getSortedRacks() {

        final ObjectResourcesSummary clusterResourcesSummary = createClusterSummarizedResources();
        final Map<String, AtomicInteger> scheduledCount = getScheduledExecCntByRackId();

        return sortObjectResources(
            clusterResourcesSummary,
            exec,
            (rackId) -> {
                AtomicInteger count = scheduledCount.get(rackId);
                if (count == null) {
                    return 0;
                }
                return count.get();
            });
    }
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



storm-server/src/main/java/org/apache/storm/scheduler/resource/strategies/scheduling/sorter/NodeSorter.java [583:598]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    public List<ObjectResourcesItem> getSortedRacks() {

        final ObjectResourcesSummary clusterResourcesSummary = createClusterSummarizedResources();
        final Map<String, AtomicInteger> scheduledCount = getScheduledExecCntByRackId();

        return sortObjectResources(
            clusterResourcesSummary,
            exec,
            (rackId) -> {
                AtomicInteger count = scheduledCount.get(rackId);
                if (count == null) {
                    return 0;
                }
                return count.get();
            });
    }
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



