com.groupbyinc.flux.action.search.FetchSearchPhase.class Maven / Gradle / Ivy
???? 4 2com/groupbyinc/flux/action/search/FetchSearchPhase -com/groupbyinc/flux/action/search/SearchPhase FetchSearchPhase.java 4com/groupbyinc/flux/action/search/FetchSearchPhase$3 4com/groupbyinc/flux/action/search/FetchSearchPhase$2 4com/groupbyinc/flux/action/search/FetchSearchPhase$1
Gcom/groupbyinc/flux/action/search/InitialSearchPhase$SearchPhaseResults 4com/groupbyinc/flux/action/search/InitialSearchPhase SearchPhaseResults 2com/groupbyinc/flux/transport/Transport$Connection 'com/groupbyinc/flux/transport/Transport
Connection Icom/groupbyinc/flux/action/search/SearchPhaseController$ReducedQueryPhase 7com/groupbyinc/flux/action/search/SearchPhaseController ReducedQueryPhase %java/lang/invoke/MethodHandles$Lookup java/lang/invoke/MethodHandles Lookup fetchResults 8Lcom/groupbyinc/flux/common/util/concurrent/AtomicArray; nLcom/groupbyinc/flux/common/util/concurrent/AtomicArray; searchPhaseController 9Lcom/groupbyinc/flux/action/search/SearchPhaseController; queryResults hLcom/groupbyinc/flux/common/util/concurrent/AtomicArray; nextPhaseFactory Ljava/util/function/BiFunction; ?Ljava/util/function/BiFunction; context 6Lcom/groupbyinc/flux/action/search/SearchPhaseContext; logger !Lorg/apache/logging/log4j/Logger; resultConsumer ILcom/groupbyinc/flux/action/search/InitialSearchPhase$SearchPhaseResults; yLcom/groupbyinc/flux/action/search/InitialSearchPhase$SearchPhaseResults; $assertionsDisabled Z ?(Lcom/groupbyinc/flux/action/search/InitialSearchPhase$SearchPhaseResults;Lcom/groupbyinc/flux/action/search/SearchPhaseController;Lcom/groupbyinc/flux/action/search/SearchPhaseContext;)V "java/lang/invoke/LambdaMetafactory 5 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; 7 8
6 9 : 8(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object; < lambda$new$1 ?(Lcom/groupbyinc/flux/action/search/SearchPhaseContext;Lcom/groupbyinc/flux/search/internal/InternalSearchResponse;Ljava/lang/String;)Lcom/groupbyinc/flux/action/search/SearchPhase; > ?
@ A (Lcom/groupbyinc/flux/search/internal/InternalSearchResponse;Ljava/lang/String;)Lcom/groupbyinc/flux/action/search/SearchPhase; C apply W(Lcom/groupbyinc/flux/action/search/SearchPhaseContext;)Ljava/util/function/BiFunction; E F G ?(Lcom/groupbyinc/flux/action/search/InitialSearchPhase$SearchPhaseResults;Lcom/groupbyinc/flux/action/search/SearchPhaseController;Lcom/groupbyinc/flux/action/search/SearchPhaseContext;Ljava/util/function/BiFunction;)V 3 I
J this 4Lcom/groupbyinc/flux/action/search/FetchSearchPhase; fetch N (Ljava/lang/String;)V 3 P
Q 4com/groupbyinc/flux/action/search/SearchPhaseContext S getNumShards ()I U V T W
W java/lang/IllegalStateException Z java/lang/StringBuilder \ ()V 3 ^
] _ Hnumber of shards must match the length of the query results but doesn't: a append -(Ljava/lang/String;)Ljava/lang/StringBuilder; c d
] e (I)Ljava/lang/StringBuilder; c g
] h != j toString ()Ljava/lang/String; l m
] n
[ Q java/util/function/BiFunction q 6com/groupbyinc/flux/common/util/concurrent/AtomicArray s (I)V 3 u
t v ! x # $ z getAtomicArray :()Lcom/groupbyinc/flux/common/util/concurrent/AtomicArray; | }
~ % ! ? ' ( ? * + ? getLogger #()Lorg/apache/logging/log4j/Logger; ? ? T ? , - ? . / ? run java/io/IOException ? b(Lcom/groupbyinc/flux/action/search/FetchSearchPhase;Lcom/groupbyinc/flux/action/ActionListener;)V 3 ?
? execute (Ljava/lang/Runnable;)V ? ? T ? innerRun
getRequest 3()Lcom/groupbyinc/flux/action/search/SearchRequest; ? ? T ? /com/groupbyinc/flux/action/search/SearchRequest ? scroll %()Lcom/groupbyinc/flux/search/Scroll; ? ?
? ? asList ()Ljava/util/List; ? ?
t ? 7com/groupbyinc/flux/action/search/TransportSearchHelper ?
buildScrollId L(Lcom/groupbyinc/flux/common/util/concurrent/AtomicArray;)Ljava/lang/String; ? ?
? ? java/util/List ? java/lang/String ? reduce M()Lcom/groupbyinc/flux/action/search/SearchPhaseController$ReducedQueryPhase; ? ?
? length ? V
t ? ^ lambda$innerRun$2 a(Ljava/lang/String;Lcom/groupbyinc/flux/action/search/SearchPhaseController$ReducedQueryPhase;Z)V ? ?
? ? ?(Lcom/groupbyinc/flux/action/search/FetchSearchPhase;Ljava/lang/String;Lcom/groupbyinc/flux/action/search/SearchPhaseController$ReducedQueryPhase;Z)Ljava/lang/Runnable; ? ? ? 1 2 ? isEmpty ()Z ? ? ? ? get (I)Ljava/lang/Object; ? ? ? ? ,com/groupbyinc/flux/search/SearchPhaseResult ? fetchResult 6()Lcom/groupbyinc/flux/search/fetch/FetchSearchResult; ? ?
? ? java/lang/AssertionError ? phaseResults empty [ ? (Z)Ljava/lang/StringBuilder; c ?
] ? ], single result: ? -(Ljava/lang/Object;)Ljava/lang/StringBuilder; c ?
] ? (Ljava/lang/Object;)V 3 ?
? ? java/lang/Runnable ? ? ^ ? ? scoreDocs ;[Lcom/groupbyinc/flux/common/apache/lucene/search/ScoreDoc; ? ? ? fillDocIdsToLoad z(I[Lcom/groupbyinc/flux/common/apache/lucene/search/ScoreDoc;)[Lcom/groupbyinc/flux/common/carrotsearch/hppc/IntArrayList; ? ?
? stream ()Ljava/util/stream/Stream; ? ? ? ? &(Ljava/lang/Object;)Ljava/lang/Object; ? queryResult 6()Lcom/groupbyinc/flux/search/query/QuerySearchResult; ? ?
? ? ? d(Lcom/groupbyinc/flux/search/SearchPhaseResult;)Lcom/groupbyinc/flux/search/query/QuerySearchResult; ? ()Ljava/util/function/Function; E ? ? java/util/stream/Stream ? map 8(Ljava/util/function/Function;)Ljava/util/stream/Stream; ? ? ? ? releaseIrrelevantSearchContext 7(Lcom/groupbyinc/flux/search/query/QuerySearchResult;)V
accept S(Lcom/groupbyinc/flux/action/search/FetchSearchPhase;)Ljava/util/function/Consumer;
forEach (Ljava/util/function/Consumer;)V
? <[Lcom/groupbyinc/flux/common/carrotsearch/hppc/IntArrayList; getLastEmittedDocPerShard ?(Lcom/groupbyinc/flux/action/search/SearchPhaseController$ReducedQueryPhase;I)[Lcom/groupbyinc/flux/common/apache/lucene/search/ScoreDoc;
? 2com/groupbyinc/flux/action/search/CountedCollector lambda$innerRun$3 7(Lcom/groupbyinc/flux/search/fetch/FetchSearchResult;)V
k(Ljava/util/function/Consumer;ILjava/lang/Runnable;Lcom/groupbyinc/flux/action/search/SearchPhaseContext;)V 3!
"
t ? 9com/groupbyinc/flux/common/carrotsearch/hppc/IntArrayList% countDown' ^
( getSearchShardTarget 0()Lcom/groupbyinc/flux/search/SearchShardTarget;*+
?, ,com/groupbyinc/flux/search/SearchShardTarget. getClusterAlias0 m
/1 getNodeId3 m
/4
getConnection Z(Ljava/lang/String;Ljava/lang/String;)Lcom/groupbyinc/flux/transport/Transport$Connection;67 T8 2com/groupbyinc/flux/search/query/QuerySearchResult: getRequestId ()J<=
;> getOriginalIndices .()Lcom/groupbyinc/flux/action/OriginalIndices;@A
/B createFetchRequest ?(JILcom/groupbyinc/flux/common/carrotsearch/hppc/IntArrayList;[Lcom/groupbyinc/flux/common/apache/lucene/search/ScoreDoc;Lcom/groupbyinc/flux/action/OriginalIndices;)Lcom/groupbyinc/flux/search/fetch/ShardFetchSearchRequest;DE
F executeFetch(ILcom/groupbyinc/flux/search/SearchShardTarget;Lcom/groupbyinc/flux/action/search/CountedCollector;Lcom/groupbyinc/flux/search/fetch/ShardFetchSearchRequest;Lcom/groupbyinc/flux/search/query/QuerySearchResult;Lcom/groupbyinc/flux/transport/Transport$Connection;)VHI
J searchShardTarget .Lcom/groupbyinc/flux/search/SearchShardTarget;
connection 4Lcom/groupbyinc/flux/transport/Transport$Connection; fetchSearchRequest :Lcom/groupbyinc/flux/search/fetch/ShardFetchSearchRequest; entry ;Lcom/groupbyinc/flux/common/carrotsearch/hppc/IntArrayList; .Lcom/groupbyinc/flux/search/SearchPhaseResult; i I lastEmittedDocPerShard counter jLcom/groupbyinc/flux/action/search/CountedCollector; 4Lcom/groupbyinc/flux/action/search/CountedCollector; docIdsToLoad numShards isScrollSearch phaseResults @Ljava/util/List; Ljava/util/List; scrollId Ljava/lang/String; reducedQueryPhase KLcom/groupbyinc/flux/action/search/SearchPhaseController$ReducedQueryPhase; queryAndFetchOptimization finishPhase Ljava/lang/Runnable; 8com/groupbyinc/flux/common/apache/lucene/search/ScoreDoch 8com/groupbyinc/flux/search/fetch/ShardFetchSearchRequestj ?(Lcom/groupbyinc/flux/action/OriginalIndices;JLcom/groupbyinc/flux/common/carrotsearch/hppc/IntArrayList;Lcom/groupbyinc/flux/common/apache/lucene/search/ScoreDoc;)V 3l
km queryId J index originalIndices ,Lcom/groupbyinc/flux/action/OriginalIndices; lastEmittedDoc :Lcom/groupbyinc/flux/common/apache/lucene/search/ScoreDoc; getSearchTransport <()Lcom/groupbyinc/flux/action/search/SearchTransportService;vw Tx getTask 0()Lcom/groupbyinc/flux/action/search/SearchTask;z{ T|7(Lcom/groupbyinc/flux/action/search/FetchSearchPhase;Lcom/groupbyinc/flux/search/SearchShardTarget;ILcom/groupbyinc/flux/action/search/CountedCollector;Lcom/groupbyinc/flux/search/fetch/ShardFetchSearchRequest;ILcom/groupbyinc/flux/search/SearchShardTarget;Lcom/groupbyinc/flux/search/query/QuerySearchResult;)V 3~
8com/groupbyinc/flux/action/search/SearchTransportService? sendExecuteFetch ?(Lcom/groupbyinc/flux/transport/Transport$Connection;Lcom/groupbyinc/flux/search/fetch/ShardFetchSearchRequest;Lcom/groupbyinc/flux/action/search/SearchTask;Lcom/groupbyinc/flux/action/search/SearchActionListener;)V??
??
shardIndex shardTarget querySearchResult 4Lcom/groupbyinc/flux/search/query/QuerySearchResult; java/lang/Exception? hasSearchContext? ?
;?
;, sendReleaseSearchContext d(JLcom/groupbyinc/flux/transport/Transport$Connection;Lcom/groupbyinc/flux/action/OriginalIndices;)V?? T? failed to release context? org/apache/logging/log4j/Logger? trace *(Ljava/lang/String;Ljava/lang/Throwable;)V???? e Ljava/lang/Exception; moveToNextPhase ?(Lcom/groupbyinc/flux/action/search/SearchPhaseController;Ljava/lang/String;Lcom/groupbyinc/flux/action/search/SearchPhaseController$ReducedQueryPhase;Lcom/groupbyinc/flux/common/util/concurrent/AtomicArray;)V java/util/Objects? requireNonNull? ?
?? ?$ 1(I)Lcom/groupbyinc/flux/search/SearchPhaseResult;? Z(Lcom/groupbyinc/flux/common/util/concurrent/AtomicArray;)Ljava/util/function/IntFunction; E? ? merge ?(ZLcom/groupbyinc/flux/action/search/SearchPhaseController$ReducedQueryPhase;Ljava/util/Collection;Ljava/util/function/IntFunction;)Lcom/groupbyinc/flux/search/internal/InternalSearchResponse;??
? E < r? executeNextPhase a(Lcom/groupbyinc/flux/action/search/SearchPhase;Lcom/groupbyinc/flux/action/search/SearchPhase;)V?? T? fetchResultsArr iLcom/groupbyinc/flux/common/util/concurrent/AtomicArray<+Lcom/groupbyinc/flux/search/SearchPhaseResult;>; internalResponse