
com.groupbyinc.flux.gateway.AsyncShardFetch.class Maven / Gradle / Ivy
???? 3? +com/groupbyinc/flux/gateway/AsyncShardFetch ~Ljava/lang/Object;Lcom/groupbyinc/flux/common/lease/Releasable; java/lang/Object +com/groupbyinc/flux/common/lease/Releasable AsyncShardFetch.java 5com/groupbyinc/flux/gateway/AsyncShardFetch$NodeEntry NodeEntry 7com/groupbyinc/flux/gateway/AsyncShardFetch$FetchResult FetchResult 0com/groupbyinc/flux/gateway/AsyncShardFetch$List List -com/groupbyinc/flux/gateway/AsyncShardFetch$1 java/util/Map$Entry
java/util/Map Entry logger -Lcom/groupbyinc/flux/common/logging/ESLogger; type Ljava/lang/String; shardId )Lcom/groupbyinc/flux/index/shard/ShardId; action 2Lcom/groupbyinc/flux/gateway/AsyncShardFetch$List; xLcom/groupbyinc/flux/gateway/AsyncShardFetch$List;TT;>; cache Ljava/util/Map; _Ljava/util/Map;>;
nodesToIgnore Ljava/util/Set; #Ljava/util/Set; closed Z ?(Lcom/groupbyinc/flux/common/logging/ESLogger;Ljava/lang/String;Lcom/groupbyinc/flux/index/shard/ShardId;Lcom/groupbyinc/flux/gateway/AsyncShardFetch$List;)V ()V * ,
- java/util/HashMap /
0 - " # 2 java/util/HashSet 4
5 - % & 7 9 ; = ? this 2Lcom/groupbyinc/flux/gateway/AsyncShardFetch; -Lcom/groupbyinc/flux/gateway/AsyncShardFetch; yLcom/groupbyinc/flux/gateway/AsyncShardFetch$List<+Lcom/groupbyinc/flux/action/support/nodes/BaseNodesResponse;TT;>; close ( ) F getNumberOfInFlightFetches ()I values ()Ljava/util/Collection; J K L java/util/Collection N iterator ()Ljava/util/Iterator; P Q O R java/util/Iterator T hasNext ()Z V W U X next ()Ljava/lang/Object; Z [ U \
isFetching ^ W
_ nodeEntry ; 7Lcom/groupbyinc/flux/gateway/AsyncShardFetch$NodeEntry; count I fetchData ?(Lcom/groupbyinc/flux/cluster/node/DiscoveryNodes;Lcom/groupbyinc/flux/cluster/metadata/MetaData;Ljava/util/Set;)Lcom/groupbyinc/flux/gateway/AsyncShardFetch$FetchResult; java/lang/IllegalStateException h java/lang/StringBuilder j
k - append -(Ljava/lang/Object;)Ljava/lang/StringBuilder; m n
k o (: can't fetch data on closed async fetch q -(Ljava/lang/String;)Ljava/lang/StringBuilder; m s
k t toString ()Ljava/lang/String; v w
k x (Ljava/lang/String;)V * z
i {
java/util/Set } addAll (Ljava/util/Collection;)Z ? ~ ? fillShardCacheWithDataNodes C(Ljava/util/Map;Lcom/groupbyinc/flux/cluster/node/DiscoveryNodes;)V ? ?
? findNodesToFetch (Ljava/util/Map;)Ljava/util/Set; ? ?
? isEmpty ? W ~ ? ~ R markAsFetching ? ,
? size ? I ~ ? java/lang/String ? [Ljava/lang/String; ? getNodeId ? w
?
asyncFetch n(Lcom/groupbyinc/flux/index/shard/ShardId;[Ljava/lang/String;Lcom/groupbyinc/flux/cluster/metadata/MetaData;)V ? ?
? hasAnyNodeFetching (Ljava/util/Map;)Z ? ?
? =com/groupbyinc/flux/common/google/common/collect/ImmutableSet ? of A()Lcom/groupbyinc/flux/common/google/common/collect/ImmutableSet; ? ?
? ? Y(Lcom/groupbyinc/flux/index/shard/ShardId;Ljava/util/Map;Ljava/util/Set;Ljava/util/Set;)V * ?
? entrySet ()Ljava/util/Set; ? ? ? getKey ? [ ? getValue ? [ ? /com/groupbyinc/flux/cluster/node/DiscoveryNodes ? get D(Ljava/lang/String;)Lcom/groupbyinc/flux/cluster/node/DiscoveryNode; ? ?
? ? isFailed ? W
? remove ? , U ? add (Ljava/lang/Object;)Z ? ? ~ ? -com/groupbyinc/flux/cluster/metadata/MetaData ? .com/groupbyinc/flux/cluster/node/DiscoveryNode ?
? put 8(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object; ? ? ? copyOf W(Ljava/util/Collection;)Lcom/groupbyinc/flux/common/google/common/collect/ImmutableSet; ? ?
? ? clear ? , ~ ? nodes failed [ ? (I)Ljava/lang/StringBuilder; m ?
k ? ], ignored [ ? ] ? reroute >(Lcom/groupbyinc/flux/index/shard/ShardId;Ljava/lang/String;)V ? ?
? nodesIds index entry eLjava/util/Map$Entry;>; Ljava/util/Map$Entry; nodeId node 0Lcom/groupbyinc/flux/cluster/node/DiscoveryNode; it {Ljava/util/Iterator;>;>; Ljava/util/Iterator; DLjava/util/Map; failedNodes allIgnoreNodes nodes 1Lcom/groupbyinc/flux/cluster/node/DiscoveryNodes; metaData /Lcom/groupbyinc/flux/cluster/metadata/MetaData; ignoreNodes nodesToFetch MLjava/util/Set;>; processAsyncFetch ?(Lcom/groupbyinc/flux/index/shard/ShardId;[Lcom/groupbyinc/flux/action/support/nodes/BaseNodeResponse;[Lcom/groupbyinc/flux/action/FailedNodeException;)V 0{} ignoring fetched [{}] results, already closed ? +com/groupbyinc/flux/common/logging/ESLogger ? trace ((Ljava/lang/String;[Ljava/lang/Object;)V ? ? "{} processing fetched [{}] results <[Lcom/groupbyinc/flux/action/support/nodes/BaseNodeResponse; 9com/groupbyinc/flux/action/support/nodes/BaseNodeResponse getNode 2()Lcom/groupbyinc/flux/cluster/node/DiscoveryNode;
getId
w
? &(Ljava/lang/Object;)Ljava/lang/Object; ? -{} node {} has failed for [{}] (failure [{}])
getFailure ()Ljava/lang/Throwable;
{} marking {} as done for [{}] doneFetching (Ljava/lang/Object;)V
1[Lcom/groupbyinc/flux/action/FailedNodeException; !{} processing failure {} for [{}]! .com/groupbyinc/flux/action/FailedNodeException# ? w
$% getCause'
$( $com/groupbyinc/flux/ExceptionsHelper* unwrapCause ,(Ljava/lang/Throwable;)Ljava/lang/Throwable;,-
+. Gcom/groupbyinc/flux/common/util/concurrent/EsRejectedExecutionException0 >com/groupbyinc/flux/transport/ReceiveTimeoutTransportException2 1com/groupbyinc/flux/ElasticsearchTimeoutException4 java/lang/Throwable6 restartFetching8 ,
9 ,{}: failed to list shard for {} on node [{}]; warn =(Ljava/lang/String;Ljava/lang/Throwable;[Ljava/lang/Object;)V=> ?? (Ljava/lang/Throwable;)VA
B
post_responseD response TT; ;Lcom/groupbyinc/flux/action/support/nodes/BaseNodeResponse; unwrappedCause Ljava/lang/Throwable; failure 0Lcom/groupbyinc/flux/action/FailedNodeException; responses [TT; failures dataNodes 7()Lcom/groupbyinc/flux/common/collect/ImmutableOpenMap;PQ
?R 3com/groupbyinc/flux/common/collect/ImmutableOpenMapT
U R Gcom/groupbyinc/flux/common/carrotsearch/hppc/cursors/ObjectObjectCursorW value Ljava/lang/Object;YZ X[ containsKey] ? ^
{ keySeta ? b
nodeExists (Ljava/lang/String;)Zde
?f cursor ?Lcom/groupbyinc/flux/common/carrotsearch/hppc/cursors/ObjectObjectCursor; ILcom/groupbyinc/flux/common/carrotsearch/hppc/cursors/ObjectObjectCursor; (Ljava/util/Iterator;
shardCache hasDatam W
n 'com/groupbyinc/flux/index/shard/ShardIdp getIndexr w
qs H(Ljava/lang/String;)Lcom/groupbyinc/flux/cluster/metadata/IndexMetaData; ?u
?v {} fetching [{}] from {}x l(Lcom/groupbyinc/flux/gateway/AsyncShardFetch;Lcom/groupbyinc/flux/index/shard/ShardId;[Ljava/lang/String;)V *z
{ list ?(Lcom/groupbyinc/flux/index/shard/ShardId;Lcom/groupbyinc/flux/cluster/metadata/IndexMetaData;[Ljava/lang/String;Lcom/groupbyinc/flux/action/ActionListener;)V}~
indexMetaData 4Lcom/groupbyinc/flux/cluster/metadata/IndexMetaData; Signature Code LocalVariableTable LocalVariableTypeTable LineNumberTable ?(Lcom/groupbyinc/flux/common/logging/ESLogger;Ljava/lang/String;Lcom/groupbyinc/flux/index/shard/ShardId;Lcom/groupbyinc/flux/gateway/AsyncShardFetch$List<+Lcom/groupbyinc/flux/action/support/nodes/BaseNodesResponse;TT;>;)V
StackMapTable ?(Lcom/groupbyinc/flux/cluster/node/DiscoveryNodes;Lcom/groupbyinc/flux/cluster/metadata/MetaData;Ljava/util/Set;)Lcom/groupbyinc/flux/gateway/AsyncShardFetch$FetchResult; a(Lcom/groupbyinc/flux/index/shard/ShardId;[TT;[Lcom/groupbyinc/flux/action/FailedNodeException;)V ?(Ljava/util/Map;>;Lcom/groupbyinc/flux/cluster/node/DiscoveryNodes;)V ?(Ljava/util/Map;>;)Ljava/util/Set;>; b(Ljava/util/Map;>;)Z
SourceFile InnerClasses! ? ! " # ? $ % &