Java Code Examples for org.elasticsearch.search.internal.SearchContext#groupStats()
The following examples show how to use
org.elasticsearch.search.internal.SearchContext#groupStats() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: ShardSearchStats.java From Elasticsearch with Apache License 2.0 | 5 votes |
public void onPreQueryPhase(SearchContext searchContext) { totalStats.queryCurrent.inc(); if (searchContext.groupStats() != null) { for (int i = 0; i < searchContext.groupStats().size(); i++) { groupStats(searchContext.groupStats().get(i)).queryCurrent.inc(); } } }
Example 2
Source File: ShardSearchStats.java From Elasticsearch with Apache License 2.0 | 5 votes |
public void onFailedQueryPhase(SearchContext searchContext) { totalStats.queryCurrent.dec(); if (searchContext.groupStats() != null) { for (int i = 0; i < searchContext.groupStats().size(); i++) { groupStats(searchContext.groupStats().get(i)).queryCurrent.dec(); } } }
Example 3
Source File: ShardSearchStats.java From Elasticsearch with Apache License 2.0 | 5 votes |
public void onQueryPhase(SearchContext searchContext, long tookInNanos) { totalStats.queryMetric.inc(tookInNanos); totalStats.queryCurrent.dec(); if (searchContext.groupStats() != null) { for (int i = 0; i < searchContext.groupStats().size(); i++) { StatsHolder statsHolder = groupStats(searchContext.groupStats().get(i)); statsHolder.queryMetric.inc(tookInNanos); statsHolder.queryCurrent.dec(); } } slowLogSearchService.onQueryPhase(searchContext, tookInNanos); }
Example 4
Source File: ShardSearchStats.java From Elasticsearch with Apache License 2.0 | 5 votes |
public void onPreFetchPhase(SearchContext searchContext) { totalStats.fetchCurrent.inc(); if (searchContext.groupStats() != null) { for (int i = 0; i < searchContext.groupStats().size(); i++) { groupStats(searchContext.groupStats().get(i)).fetchCurrent.inc(); } } }
Example 5
Source File: ShardSearchStats.java From Elasticsearch with Apache License 2.0 | 5 votes |
public void onFailedFetchPhase(SearchContext searchContext) { totalStats.fetchCurrent.dec(); if (searchContext.groupStats() != null) { for (int i = 0; i < searchContext.groupStats().size(); i++) { groupStats(searchContext.groupStats().get(i)).fetchCurrent.dec(); } } }
Example 6
Source File: ShardSearchStats.java From Elasticsearch with Apache License 2.0 | 5 votes |
public void onFetchPhase(SearchContext searchContext, long tookInNanos) { totalStats.fetchMetric.inc(tookInNanos); totalStats.fetchCurrent.dec(); if (searchContext.groupStats() != null) { for (int i = 0; i < searchContext.groupStats().size(); i++) { StatsHolder statsHolder = groupStats(searchContext.groupStats().get(i)); statsHolder.fetchMetric.inc(tookInNanos); statsHolder.fetchCurrent.dec(); } } slowLogSearchService.onFetchPhase(searchContext, tookInNanos); }