Package org.elasticsearch.ingest
Interface Processor
-
- All Known Subinterfaces:
WrappingProcessor
- All Known Implementing Classes:
AbstractProcessor,CompoundProcessor,ConditionalProcessor,PipelineProcessor,TrackingResultProcessor
public interface ProcessorA processor implementation may modify the data belonging to a document. Whether changes are made and what exactly is modified is up to the implementation. Processors may get called concurrently and thus need to be thread-safe.
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static interfaceProcessor.FactoryA factory that knows how to construct a processor based on a map of maps.static classProcessor.ParametersInfrastructure class that holds services that can be used by processor factories to create processor instances and that gets passed around to allIngestPlugins.
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description IngestDocumentexecute(IngestDocument ingestDocument)Introspect and potentially modify the incoming data.default voidexecute(IngestDocument ingestDocument, BiConsumer<IngestDocument,Exception> handler)Introspect and potentially modify the incoming data.StringgetTag()Gets the tag of a processor.StringgetType()Gets the type of a processor
-
-
-
Method Detail
-
execute
default void execute(IngestDocument ingestDocument, BiConsumer<IngestDocument,Exception> handler)
Introspect and potentially modify the incoming data. Expert method: only override this method if a processor implementation needs to make an asynchronous call, otherwise just overwriteexecute(IngestDocument).
-
execute
IngestDocument execute(IngestDocument ingestDocument) throws Exception
Introspect and potentially modify the incoming data.- Returns:
- If
nullis returned then the current document will be dropped and not be indexed, otherwise this document will be kept and indexed - Throws:
Exception
-
getType
String getType()
Gets the type of a processor
-
getTag
String getTag()
Gets the tag of a processor.
-
-