Class ShardSearchStats
java.lang.Object
org.elasticsearch.index.search.stats.ShardSearchStats
- All Implemented Interfaces:
SearchOperationListener
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.elasticsearch.index.shard.SearchOperationListener
SearchOperationListener.CompositeListener
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
onFailedFetchPhase(SearchContext searchContext)
Executed if a fetch phased failed.void
onFailedQueryPhase(SearchContext searchContext)
Executed if a query phased failed.void
onFetchPhase(SearchContext searchContext, long tookInNanos)
Executed after the fetch phase successfully finished.void
onFreeReaderContext(ReaderContext readerContext)
Executed when a previously created reader context is freed.void
onFreeScrollContext(ReaderContext readerContext)
Executed when a scroll searchSearchContext
is freed.void
onNewReaderContext(ReaderContext readerContext)
Executed when a new reader context was createdvoid
onNewScrollContext(ReaderContext readerContext)
Executed when a new scroll searchReaderContext
was createdvoid
onPreFetchPhase(SearchContext searchContext)
Executed before the fetch phase is executedvoid
onPreQueryPhase(SearchContext searchContext)
Executed before the query phase is executedvoid
onQueryPhase(SearchContext searchContext, long tookInNanos)
Executed after the query phase successfully finished.Returns the stats, including group specific stats.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.elasticsearch.index.shard.SearchOperationListener
validateReaderContext
-
Constructor Details
-
ShardSearchStats
public ShardSearchStats()
-
-
Method Details
-
stats
Returns the stats, including group specific stats. If the groups are null/0 length, then nothing is returned for them. If they are set, then only groups provided will be returned, or_all
for all groups. -
onPreQueryPhase
Description copied from interface:SearchOperationListener
Executed before the query phase is executed- Specified by:
onPreQueryPhase
in interfaceSearchOperationListener
- Parameters:
searchContext
- the current search context
-
onFailedQueryPhase
Description copied from interface:SearchOperationListener
Executed if a query phased failed.- Specified by:
onFailedQueryPhase
in interfaceSearchOperationListener
- Parameters:
searchContext
- the current search context
-
onQueryPhase
Description copied from interface:SearchOperationListener
Executed after the query phase successfully finished. Note: this is not invoked if the query phase execution failed.- Specified by:
onQueryPhase
in interfaceSearchOperationListener
- Parameters:
searchContext
- the current search contexttookInNanos
- the number of nanoseconds the query execution took- See Also:
SearchOperationListener.onFailedQueryPhase(SearchContext)
-
onPreFetchPhase
Description copied from interface:SearchOperationListener
Executed before the fetch phase is executed- Specified by:
onPreFetchPhase
in interfaceSearchOperationListener
- Parameters:
searchContext
- the current search context
-
onFailedFetchPhase
Description copied from interface:SearchOperationListener
Executed if a fetch phased failed.- Specified by:
onFailedFetchPhase
in interfaceSearchOperationListener
- Parameters:
searchContext
- the current search context
-
onFetchPhase
Description copied from interface:SearchOperationListener
Executed after the fetch phase successfully finished. Note: this is not invoked if the fetch phase execution failed.- Specified by:
onFetchPhase
in interfaceSearchOperationListener
- Parameters:
searchContext
- the current search contexttookInNanos
- the number of nanoseconds the fetch execution took- See Also:
SearchOperationListener.onFailedFetchPhase(SearchContext)
-
onNewReaderContext
Description copied from interface:SearchOperationListener
Executed when a new reader context was created- Specified by:
onNewReaderContext
in interfaceSearchOperationListener
- Parameters:
readerContext
- the created context
-
onFreeReaderContext
Description copied from interface:SearchOperationListener
Executed when a previously created reader context is freed. This happens either when the search execution finishes, if the execution failed or if the search context as idle for and needs to be cleaned up.- Specified by:
onFreeReaderContext
in interfaceSearchOperationListener
- Parameters:
readerContext
- the freed reader context
-
onNewScrollContext
Description copied from interface:SearchOperationListener
Executed when a new scroll searchReaderContext
was created- Specified by:
onNewScrollContext
in interfaceSearchOperationListener
- Parameters:
readerContext
- the created reader context
-
onFreeScrollContext
Description copied from interface:SearchOperationListener
Executed when a scroll searchSearchContext
is freed. This happens either when the scroll search execution finishes, if the execution failed or if the search context as idle for and needs to be cleaned up.- Specified by:
onFreeScrollContext
in interfaceSearchOperationListener
- Parameters:
readerContext
- the freed search context
-