Package org.opensearch.search.pipeline
Class SearchPipelineService
java.lang.Object
org.opensearch.search.pipeline.SearchPipelineService
- All Implemented Interfaces:
ClusterStateApplier
,org.opensearch.core.service.ReportingService<SearchPipelineInfo>
public class SearchPipelineService
extends Object
implements ClusterStateApplier, org.opensearch.core.service.ReportingService<SearchPipelineInfo>
The main entry point for search pipelines. Handles CRUD operations and exposes the API to execute search pipelines
against requests and responses.
- Opensearch.internal:
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.opensearch.core.service.ReportingService
org.opensearch.core.service.ReportingService.Info
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionSearchPipelineService
(ClusterService clusterService, ThreadPool threadPool, Environment env, ScriptService scriptService, AnalysisRegistry analysisRegistry, org.opensearch.core.xcontent.NamedXContentRegistry namedXContentRegistry, org.opensearch.core.common.io.stream.NamedWriteableRegistry namedWriteableRegistry, List<SearchPipelinePlugin> searchPipelinePlugins, Client client) -
Method Summary
Modifier and TypeMethodDescriptionvoid
Called when a new cluster state (ClusterChangedEvent.state()
needs to be applied.void
deletePipeline
(DeleteSearchPipelineRequest request, org.opensearch.core.action.ActionListener<AcknowledgedResponse> listener) static List
<PipelineConfiguration> getPipelines
(ClusterState clusterState, String... ids) info()
void
putPipeline
(Map<DiscoveryNode, SearchPipelineInfo> searchPipelineInfos, PutSearchPipelineRequest request, org.opensearch.core.action.ActionListener<AcknowledgedResponse> listener) resolvePipeline
(SearchRequest searchRequest, IndexNameExpressionResolver indexNameExpressionResolver) stats()
-
Field Details
-
SEARCH_PIPELINE_ORIGIN
- See Also:
-
AD_HOC_PIPELINE_ID
- See Also:
-
NOOP_PIPELINE_ID
- See Also:
-
-
Constructor Details
-
SearchPipelineService
public SearchPipelineService(ClusterService clusterService, ThreadPool threadPool, Environment env, ScriptService scriptService, AnalysisRegistry analysisRegistry, org.opensearch.core.xcontent.NamedXContentRegistry namedXContentRegistry, org.opensearch.core.common.io.stream.NamedWriteableRegistry namedWriteableRegistry, List<SearchPipelinePlugin> searchPipelinePlugins, Client client)
-
-
Method Details
-
applyClusterState
Description copied from interface:ClusterStateApplier
Called when a new cluster state (ClusterChangedEvent.state()
needs to be applied. The cluster state to be applied is already committed when this method is called, so an applier must therefore be prepared to deal with any state it receives without throwing an exception. Throwing an exception from an applier is very bad because it will stop the application of this state before it has reached all the other appliers, and will likely result in another attempt to apply the same (or very similar) cluster state which might continue until this node is removed from the cluster.- Specified by:
applyClusterState
in interfaceClusterStateApplier
-
putPipeline
public void putPipeline(Map<DiscoveryNode, SearchPipelineInfo> searchPipelineInfos, PutSearchPipelineRequest request, org.opensearch.core.action.ActionListener<AcknowledgedResponse> listener) throws Exception- Throws:
Exception
-
deletePipeline
public void deletePipeline(DeleteSearchPipelineRequest request, org.opensearch.core.action.ActionListener<AcknowledgedResponse> listener) throws Exception - Throws:
Exception
-
resolvePipeline
public PipelinedRequest resolvePipeline(SearchRequest searchRequest, IndexNameExpressionResolver indexNameExpressionResolver) -
info
- Specified by:
info
in interfaceorg.opensearch.core.service.ReportingService<SearchPipelineInfo>
-
stats
-
getPipelines
-
getClusterService
-