Package org.elasticsearch.ingest
Class TestProcessor
java.lang.Object
org.elasticsearch.ingest.TestProcessor
- All Implemented Interfaces:
Processor
Processor used for testing, keeps track of how many times it is invoked and
accepts a
Consumer
of IngestDocument
to be called when executed.-
Nested Class Summary
Nested classes/interfaces inherited from interface org.elasticsearch.ingest.Processor
Processor.Parameters
-
Constructor Summary
ConstructorDescriptionTestProcessor
(String tag, String type, String description, RuntimeException e) TestProcessor
(String tag, String type, String description, Consumer<IngestDocument> ingestDocumentConsumer) TestProcessor
(String tag, String type, String description, Function<IngestDocument, IngestDocument> ingestDocumentMapper) TestProcessor
(Consumer<IngestDocument> ingestDocumentConsumer) -
Method Summary
Modifier and TypeMethodDescriptionexecute
(IngestDocument ingestDocument) void
execute
(IngestDocument ingestDocument, BiConsumer<IngestDocument, Exception> handler) int
getTag()
getType()
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.elasticsearch.ingest.Processor
extraValidation, isAsync
-
Constructor Details
-
TestProcessor
-
TestProcessor
-
TestProcessor
-
TestProcessor
public TestProcessor(String tag, String type, String description, Consumer<IngestDocument> ingestDocumentConsumer) -
TestProcessor
public TestProcessor(String tag, String type, String description, Function<IngestDocument, IngestDocument> ingestDocumentMapper)
-
-
Method Details
-
execute
-
execute
-
getType
-
getTag
-
getDescription
- Specified by:
getDescription
in interfaceProcessor
-
getInvokedCounter
public int getInvokedCounter()
-