public List<ShardRouting> shardsWithState(ShardRoutingState state) { List<ShardRouting> shards = new ArrayList<>(); for (IndexRoutingTable indexRoutingTable : this) { shards.addAll(indexRoutingTable.shardsWithState(state)); } return shards; }
Map<String, AtomicInteger> nodesToNumRouting = new HashMap<>(); int numShards = sourceMetaData.getNumberOfShards(); for (ShardRouting routing : table.shardsWithState(ShardRoutingState.STARTED)) { nodesToNumRouting.computeIfAbsent(routing.currentNodeId(), (s) -> new AtomicInteger(0)).incrementAndGet();
public List<ShardRouting> shardsWithState(ShardRoutingState state) { List<ShardRouting> shards = new ArrayList<>(); for (IndexRoutingTable indexRoutingTable : this) { shards.addAll(indexRoutingTable.shardsWithState(state)); } return shards; }
public List<ShardRouting> shardsWithState(ShardRoutingState state) { List<ShardRouting> shards = new ArrayList<>(); for (IndexRoutingTable indexRoutingTable : this) { shards.addAll(indexRoutingTable.shardsWithState(state)); } return shards; }
public List<ShardRouting> shardsWithState(ShardRoutingState state) { List<ShardRouting> shards = new ArrayList<>(); for (IndexRoutingTable indexRoutingTable : this) { shards.addAll(indexRoutingTable.shardsWithState(state)); } return shards; }
public List<ShardRouting> shardsWithState(ShardRoutingState state) { List<ShardRouting> shards = new ArrayList<>(); for (IndexRoutingTable indexRoutingTable : this) { shards.addAll(indexRoutingTable.shardsWithState(state)); } return shards; }
Map<String, AtomicInteger> nodesToNumRouting = new HashMap<>(); int numShards = sourceMetaData.getNumberOfShards(); for (ShardRouting routing : table.shardsWithState(ShardRoutingState.STARTED)) { nodesToNumRouting.computeIfAbsent(routing.currentNodeId(), (s) -> new AtomicInteger(0)).incrementAndGet();
Map<String, AtomicInteger> nodesToNumRouting = new HashMap<>(); int numShards = sourceMetaData.getNumberOfShards(); for (ShardRouting routing : table.shardsWithState(ShardRoutingState.STARTED)) { nodesToNumRouting.computeIfAbsent(routing.currentNodeId(), (s) -> new AtomicInteger(0)).incrementAndGet();
Map<String, AtomicInteger> nodesToNumRouting = new HashMap<>(); int numShards = sourceMetaData.getNumberOfShards(); for (ShardRouting routing : table.shardsWithState(ShardRoutingState.STARTED)) { nodesToNumRouting.computeIfAbsent(routing.currentNodeId(), (s) -> new AtomicInteger(0)).incrementAndGet();