Class Pipeline

org.elasticsearch.ingest.Pipeline

public final class Pipeline extends
A pipeline is a list of Processor instances grouped under a unique id.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static
     
    static
     
    static
     
    static
     
  • Constructor Summary

    Constructors
    Constructor
    Description
     id,  description,  version, CompoundProcessor compoundProcessor)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static Pipeline
     id, <,​> config, <,​Processor.Factory> processorFactories, ScriptService scriptService)
     
    void
    execute​(IngestDocument ingestDocument, <> handler)
    Modifies the data of a document to be indexed based on the processor this pipeline holds If null is returned then this document will be dropped and not indexed, otherwise this document will be kept and indexed.
    Flattens the normal and on failure processors into a single list.
    Get the underlying CompoundProcessor containing the Pipeline's processors
    An optional description of what this pipeline is doing to the data gets processed by this pipeline.
    The unique id of this pipeline
    org.elasticsearch.ingest.IngestMetric
    The metrics associated with this pipeline.
    Unmodifiable list containing each on_failure processor that operates on the data in case of exception thrown in pipeline processors
    Unmodifiable list containing each processor that operates on the data.
    An optional version stored with the pipeline so that it can be used to determine if the pipeline should be updated / replaced.

    Methods inherited from class java.lang.

    , , , , , , , , , ,
  • Field Details

  • Constructor Details

    • Pipeline

      public Pipeline( id, @Nullable  description, @Nullable  version, CompoundProcessor compoundProcessor)
  • Method Details

    • create

      public static  id, <,​> config, <,​Processor.Factory> processorFactories, ScriptService scriptService) throws
      Throws:
    • execute

      public void execute(IngestDocument ingestDocument, <> handler)
      Modifies the data of a document to be indexed based on the processor this pipeline holds If null is returned then this document will be dropped and not indexed, otherwise this document will be kept and indexed.
    • getId

      public  getId()
      The unique id of this pipeline
    • getDescription

      @Nullable public  getDescription()
      An optional description of what this pipeline is doing to the data gets processed by this pipeline.
    • getVersion

      @Nullable public  getVersion()
      An optional version stored with the pipeline so that it can be used to determine if the pipeline should be updated / replaced.
      Returns:
      null if not supplied.
    • getCompoundProcessor

      public CompoundProcessor getCompoundProcessor()
      Get the underlying CompoundProcessor containing the Pipeline's processors
    • getProcessors

      public <Processor> getProcessors()
      Unmodifiable list containing each processor that operates on the data.
    • getOnFailureProcessors

      public <Processor> getOnFailureProcessors()
      Unmodifiable list containing each on_failure processor that operates on the data in case of exception thrown in pipeline processors
    • flattenAllProcessors

      public <Processor> flattenAllProcessors()
      Flattens the normal and on failure processors into a single list. The original order is lost. This can be useful for pipeline validation purposes.
    • getMetrics

      public org.elasticsearch.ingest.IngestMetric getMetrics()
      The metrics associated with this pipeline.