本文整理汇总了Java中org.elasticsearch.search.fetch.FetchPhase类的典型用法代码示例。如果您正苦于以下问题:Java FetchPhase类的具体用法?Java FetchPhase怎么用?Java FetchPhase使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
FetchPhase类属于org.elasticsearch.search.fetch包,在下文中一共展示了FetchPhase类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: SearchService
import org.elasticsearch.search.fetch.FetchPhase; //导入依赖的package包/类
public SearchService(ClusterService clusterService, IndicesService indicesService,
ThreadPool threadPool, ScriptService scriptService, BigArrays bigArrays, FetchPhase fetchPhase) {
super(clusterService.getSettings());
this.threadPool = threadPool;
this.clusterService = clusterService;
this.indicesService = indicesService;
this.scriptService = scriptService;
this.bigArrays = bigArrays;
this.queryPhase = new QueryPhase(settings);
this.fetchPhase = fetchPhase;
TimeValue keepAliveInterval = KEEPALIVE_INTERVAL_SETTING.get(settings);
this.defaultKeepAlive = DEFAULT_KEEPALIVE_SETTING.get(settings).millis();
this.keepAliveReaper = threadPool.scheduleWithFixedDelay(new Reaper(), keepAliveInterval, Names.SAME);
defaultSearchTimeout = DEFAULT_SEARCH_TIMEOUT_SETTING.get(settings);
clusterService.getClusterSettings().addSettingsUpdateConsumer(DEFAULT_SEARCH_TIMEOUT_SETTING, this::setDefaultSearchTimeout);
lowLevelCancellation = LOW_LEVEL_CANCELLATION_SETTING.get(settings);
clusterService.getClusterSettings().addSettingsUpdateConsumer(LOW_LEVEL_CANCELLATION_SETTING, this::setLowLevelCancellation);
}
示例2: DefaultSearchContext
import org.elasticsearch.search.fetch.FetchPhase; //导入依赖的package包/类
DefaultSearchContext(long id, ShardSearchRequest request, SearchShardTarget shardTarget, Engine.Searcher engineSearcher,
IndexService indexService, IndexShard indexShard,
BigArrays bigArrays, Counter timeEstimateCounter, TimeValue timeout, FetchPhase fetchPhase) {
this.id = id;
this.request = request;
this.fetchPhase = fetchPhase;
this.searchType = request.searchType();
this.shardTarget = shardTarget;
this.engineSearcher = engineSearcher;
// SearchContexts use a BigArrays that can circuit break
this.bigArrays = bigArrays.withCircuitBreaking();
this.dfsResult = new DfsSearchResult(id, shardTarget);
this.queryResult = new QuerySearchResult(id, shardTarget);
this.fetchResult = new FetchSearchResult(id, shardTarget);
this.indexShard = indexShard;
this.indexService = indexService;
this.searcher = new ContextIndexSearcher(engineSearcher, indexService.cache().query(), indexShard.getQueryCachingPolicy());
this.timeEstimateCounter = timeEstimateCounter;
this.timeout = timeout;
queryShardContext = indexService.newQueryShardContext(request.shardId().id(), searcher.getIndexReader(), request::nowInMillis);
queryShardContext.setTypes(request.types());
queryBoost = request.indexBoost();
}
示例3: newSearchService
import org.elasticsearch.search.fetch.FetchPhase; //导入依赖的package包/类
@Override
protected SearchService newSearchService(ClusterService clusterService, IndicesService indicesService,
ThreadPool threadPool, ScriptService scriptService, BigArrays bigArrays,
FetchPhase fetchPhase) {
if (getPluginsService().filterPlugins(MockSearchService.TestPlugin.class).isEmpty()) {
return super.newSearchService(clusterService, indicesService, threadPool, scriptService, bigArrays, fetchPhase);
}
return new MockSearchService(clusterService, indicesService, threadPool, scriptService, bigArrays, fetchPhase);
}
示例4: TopHitsAggregator
import org.elasticsearch.search.fetch.FetchPhase; //导入依赖的package包/类
public TopHitsAggregator(FetchPhase fetchPhase, SubSearchContext subSearchContext, String name, SearchContext context,
Aggregator parent, List<PipelineAggregator> pipelineAggregators, Map<String, Object> metaData) throws IOException {
super(name, context, parent, pipelineAggregators, metaData);
this.fetchPhase = fetchPhase;
topDocsCollectors = new LongObjectPagedHashMap<>(1, context.bigArrays());
this.subSearchContext = subSearchContext;
}
示例5: TopHitsParser
import org.elasticsearch.search.fetch.FetchPhase; //导入依赖的package包/类
@Inject
public TopHitsParser(FetchPhase fetchPhase, SortParseElement sortParseElement, FetchSourceParseElement sourceParseElement,
HighlighterParseElement highlighterParseElement, FieldDataFieldsParseElement fieldDataFieldsParseElement,
ScriptFieldsParseElement scriptFieldsParseElement, FieldsParseElement fieldsParseElement) {
this.fetchPhase = fetchPhase;
this.sortParseElement = sortParseElement;
this.sourceParseElement = sourceParseElement;
this.highlighterParseElement = highlighterParseElement;
this.fieldDataFieldsParseElement = fieldDataFieldsParseElement;
this.scriptFieldsParseElement = scriptFieldsParseElement;
this.fieldsParseElement = fieldsParseElement;
}
示例6: TopHitsAggregator
import org.elasticsearch.search.fetch.FetchPhase; //导入依赖的package包/类
public TopHitsAggregator(FetchPhase fetchPhase, SubSearchContext subSearchContext, String name, AggregationContext context,
Aggregator parent, List<PipelineAggregator> pipelineAggregators, Map<String, Object> metaData) throws IOException {
super(name, context, parent, pipelineAggregators, metaData);
this.fetchPhase = fetchPhase;
topDocsCollectors = new LongObjectPagedHashMap<>(1, context.bigArrays());
this.subSearchContext = subSearchContext;
}
示例7: configureSearch
import org.elasticsearch.search.fetch.FetchPhase; //导入依赖的package包/类
protected void configureSearch() {
// configure search private classes...
bind(DfsPhase.class).asEagerSingleton();
bind(QueryPhase.class).asEagerSingleton();
bind(SearchPhaseController.class).asEagerSingleton();
bind(FetchPhase.class).asEagerSingleton();
bind(SearchServiceTransportAction.class).asEagerSingleton();
bind(MoreLikeThisFetchService.class).asEagerSingleton();
if (searchServiceImpl == SearchService.class) {
bind(SearchService.class).asEagerSingleton();
} else {
bind(SearchService.class).to(searchServiceImpl).asEagerSingleton();
}
}
示例8: DumpParser
import org.elasticsearch.search.fetch.FetchPhase; //导入依赖的package包/类
@Inject
public DumpParser(QueryPhase queryPhase, FetchPhase fetchPhase) {
Map<String, SearchParseElement> elementParsers = new HashMap<String, SearchParseElement>();
elementParsers.putAll(queryPhase.parseElements());
elementParsers.put("force_overwrite", new ExportForceOverwriteParseElement());
elementParsers.put("directory", directoryParseElement);
this.elementParsers = ImmutableMap.copyOf(elementParsers);
}
示例9: ReindexParser
import org.elasticsearch.search.fetch.FetchPhase; //导入依赖的package包/类
@Inject
public ReindexParser(QueryPhase queryPhase, FetchPhase fetchPhase) {
Map<String, SearchParseElement> elementParsers = new HashMap<String,
SearchParseElement>();
elementParsers.putAll(queryPhase.parseElements());
elementParsers.put("explain", new ExplainParseElement());
this.elementParsers = ImmutableMap.copyOf(elementParsers);
}
示例10: SearchIntoParser
import org.elasticsearch.search.fetch.FetchPhase; //导入依赖的package包/类
@Inject
public SearchIntoParser(QueryPhase queryPhase, FetchPhase fetchPhase) {
Map<String, SearchParseElement> elementParsers = new HashMap<String,
SearchParseElement>();
elementParsers.putAll(queryPhase.parseElements());
elementParsers.put("fields", new FieldsParseElement());
elementParsers.put("targetNodes", new TargetNodesParseElement());
elementParsers.put("explain", new ExplainParseElement());
this.elementParsers = ImmutableMap.copyOf(elementParsers);
}
示例11: ExportParser
import org.elasticsearch.search.fetch.FetchPhase; //导入依赖的package包/类
@Inject
public ExportParser(QueryPhase queryPhase, FetchPhase fetchPhase) {
Map<String, SearchParseElement> elementParsers = new HashMap<String, SearchParseElement>();
elementParsers.putAll(queryPhase.parseElements());
elementParsers.put("fields", new FieldsParseElement());
elementParsers.put("output_cmd", new ExportOutputCmdParseElement());
elementParsers.put("output_file", new ExportOutputFileParseElement());
elementParsers.put("force_overwrite", new ExportForceOverwriteParseElement());
elementParsers.put("compression", new ExportCompressionParseElement());
elementParsers.put("explain", new ExplainParseElement());
elementParsers.put("mappings", new ExportMappingsParseElement());
elementParsers.put("settings", new ExportSettingsParseElement());
this.elementParsers = ImmutableMap.copyOf(elementParsers);
}
示例12: MockSearchService
import org.elasticsearch.search.fetch.FetchPhase; //导入依赖的package包/类
public MockSearchService(ClusterService clusterService,
IndicesService indicesService, ThreadPool threadPool, ScriptService scriptService,
BigArrays bigArrays, FetchPhase fetchPhase) {
super(clusterService, indicesService, threadPool, scriptService, bigArrays, fetchPhase);
}
示例13: fetchPhase
import org.elasticsearch.search.fetch.FetchPhase; //导入依赖的package包/类
@Override
public FetchPhase fetchPhase() {
return null;
}
示例14: InnerHitsFetchSubPhase
import org.elasticsearch.search.fetch.FetchPhase; //导入依赖的package包/类
public InnerHitsFetchSubPhase(FetchPhase fetchPhase) {
this.fetchPhase = fetchPhase;
}
示例15: fetchPhase
import org.elasticsearch.search.fetch.FetchPhase; //导入依赖的package包/类
@Override
public FetchPhase fetchPhase() {
return in.fetchPhase();
}