com.groupbyinc.flux.gateway.GatewayAllocator.class Maven / Gradle / Ivy
???? 4% ,com/groupbyinc/flux/gateway/GatewayAllocator 6com/groupbyinc/flux/common/component/AbstractComponent GatewayAllocator.java Jcom/groupbyinc/flux/gateway/GatewayAllocator$InternalReplicaShardAllocator InternalReplicaShardAllocator Jcom/groupbyinc/flux/gateway/GatewayAllocator$InternalPrimaryShardAllocator InternalPrimaryShardAllocator ?com/groupbyinc/flux/gateway/GatewayAllocator$InternalAsyncFetch InternalAsyncFetch [com/groupbyinc/flux/gateway/TransportNodesListGatewayStartedShards$NodeGatewayStartedShards Bcom/groupbyinc/flux/gateway/TransportNodesListGatewayStartedShards NodeGatewayStartedShards ]com/groupbyinc/flux/indices/store/TransportNodesListShardStoreMetaData$NodeStoreFilesMetaData Fcom/groupbyinc/flux/indices/store/TransportNodesListShardStoreMetaData NodeStoreFilesMetaData Acom/groupbyinc/flux/cluster/routing/RoutingNodes$UnassignedShards 0com/groupbyinc/flux/cluster/routing/RoutingNodes UnassignedShards %java/lang/invoke/MethodHandles$Lookup java/lang/invoke/MethodHandles Lookup routingService 4Lcom/groupbyinc/flux/cluster/routing/RoutingService; primaryShardAllocator 3Lcom/groupbyinc/flux/gateway/PrimaryShardAllocator; replicaShardAllocator 3Lcom/groupbyinc/flux/gateway/ReplicaShardAllocator; asyncFetchStarted $Ljava/util/concurrent/ConcurrentMap; ?Ljava/util/concurrent/ConcurrentMap;>; asyncFetchStore ?Ljava/util/concurrent/ConcurrentMap;>; %(Lcom/groupbyinc/flux/common/settings/Settings;Lcom/groupbyinc/flux/cluster/service/ClusterService;Lcom/groupbyinc/flux/cluster/routing/RoutingService;Lcom/groupbyinc/flux/gateway/TransportNodesListGatewayStartedShards;Lcom/groupbyinc/flux/indices/store/TransportNodesListShardStoreMetaData;)V *Lcom/groupbyinc/flux/common/inject/Inject; 1(Lcom/groupbyinc/flux/common/settings/Settings;)V . 1
2 @com/groupbyinc/flux/common/util/concurrent/ConcurrentCollections 4 newConcurrentMap &()Ljava/util/concurrent/ConcurrentMap; 6 7
5 8 ) * : , * < # $ > ?(Lcom/groupbyinc/flux/gateway/GatewayAllocator;Lcom/groupbyinc/flux/common/settings/Settings;Lcom/groupbyinc/flux/gateway/TransportNodesListGatewayStartedShards;)V . @
A % & C ?(Lcom/groupbyinc/flux/gateway/GatewayAllocator;Lcom/groupbyinc/flux/common/settings/Settings;Lcom/groupbyinc/flux/indices/store/TransportNodesListShardStoreMetaData;)V . E
F ' ( H "java/lang/invoke/LambdaMetafactory J metafactory ?(Ljava/lang/invoke/MethodHandles$Lookup;Ljava/lang/String;Ljava/lang/invoke/MethodType;Ljava/lang/invoke/MethodType;Ljava/lang/invoke/MethodHandle;Ljava/lang/invoke/MethodType;)Ljava/lang/invoke/CallSite; L M
K N O 4(Lcom/groupbyinc/flux/cluster/ClusterChangedEvent;)V Q lambda$new$0 S Q
T U applyClusterState a(Lcom/groupbyinc/flux/gateway/GatewayAllocator;)Lcom/groupbyinc/flux/cluster/ClusterStateApplier; W X Y 2com/groupbyinc/flux/cluster/service/ClusterService [ addStateApplier 4(Lcom/groupbyinc/flux/cluster/ClusterStateApplier;)V ] ^
\ _ this .Lcom/groupbyinc/flux/gateway/GatewayAllocator; settings .Lcom/groupbyinc/flux/common/settings/Settings; clusterService 4Lcom/groupbyinc/flux/cluster/service/ClusterService;
startedAction DLcom/groupbyinc/flux/gateway/TransportNodesListGatewayStartedShards; storeAction HLcom/groupbyinc/flux/indices/store/TransportNodesListShardStoreMetaData; getNumberOfInFlightFetch ()I "java/util/concurrent/ConcurrentMap m values ()Ljava/util/Collection; o p n q java/util/Collection s iterator ()Ljava/util/Iterator; u v t w java/util/Iterator y hasNext ()Z { | z } next ()Ljava/lang/Object; ? z ? +com/groupbyinc/flux/gateway/AsyncShardFetch ? getNumberOfInFlightFetches ? l
? ? fetch ?Lcom/groupbyinc/flux/gateway/AsyncShardFetch; -Lcom/groupbyinc/flux/gateway/AsyncShardFetch; ?Lcom/groupbyinc/flux/gateway/AsyncShardFetch; count I applyStartedShards U(Lcom/groupbyinc/flux/cluster/routing/allocation/RoutingAllocation;Ljava/util/List;)V java/util/List ? ? w 0com/groupbyinc/flux/cluster/routing/ShardRouting ? +com/groupbyinc/flux/common/lease/Releasable ? shardId +()Lcom/groupbyinc/flux/index/shard/ShardId; ? ?
? ? remove &(Ljava/lang/Object;)Ljava/lang/Object; ? ? n ? ,com/groupbyinc/flux/common/lease/Releasables ? close 1([Lcom/groupbyinc/flux/common/lease/Releasable;)V ? ?
? ? startedShard 2Lcom/groupbyinc/flux/cluster/routing/ShardRouting;
allocation BLcom/groupbyinc/flux/cluster/routing/allocation/RoutingAllocation;
startedShards DLjava/util/List; Ljava/util/List; applyFailedShards :com/groupbyinc/flux/cluster/routing/allocation/FailedShard ? getRoutingEntry 4()Lcom/groupbyinc/flux/cluster/routing/ShardRouting; ? ?
? ? failedShard