Simulate a pipeline
- POST also GET /_ingest/pipeline/{id}/_simulate
- POST also GET /_ingest/pipeline/_simulate
Run an ingest pipeline against a set of provided documents. You can either specify an existing pipeline to use with the provided documents or supply a pipeline definition in the body of the request.
- Cluster privileges:
read_pipeline
Path Parameters
-
idstring Idoptional -
The pipeline to test. If you don't specify a
pipelinein the request body, this parameter is required.Leave it out to use
/_ingest/pipeline/_simulate.
Query Parameters
-
verboseboolean · default: false If
true, the response includes output data for each processor in the executed pipeline.
Request
-
docsDocumentrequired -
Sample documents to test in the pipeline.
-
pipelinePipeline -
The pipeline to test. If you don't specify the
pipelinerequest path parameter, this parameter is required. If you specify both this and the request path parameter, the API only uses the request path parameter. -
descriptionstring -
Description of the ingest pipeline.
-
on_failureProcessorContainer -
Processors to run immediately after a processor failure.
-
processorsProcessorContainer -
Processors used to perform transformations on documents before indexing. Processors run sequentially in the order specified.
-
versionnumber VersionNumber -
Version number used by external systems to track ingest pipelines.
-
deprecatedboolean · default: false -
Marks this ingest pipeline as deprecated. When a deprecated ingest pipeline is referenced as the default or final pipeline when creating or updating a non-deprecated index template, Elasticsearch will emit a deprecation warning.
-
_metaMetadata -
Arbitrary metadata about the ingest pipeline. This map is not automatically generated by Elasticsearch.
Response
-
docsSimulateDocumentResultrequired -
docDocumentSimulation -
_idstring Idrequired -
Unique identifier for the document. This ID must be unique within the
_index. -
_indexstring IndexNamerequired -
Name of the index containing the document.
-
_ingestIngestrequired -
_redactRedact -
_is_redactedbooleanrequired -
indicates if document has been redacted
-
timestampDateTimerequired -
pipelinestring Name -
_routingstring -
Value used to send the document to a specific primary shard.
-
_sourcemap string to objectrequired -
JSON body for the document.
-
_versionStringifiedVersionNumber -
_version_typeVersionType -
Supported values include:
internal: Use internal versioning that starts at 1 and increments with each update or delete.external: Only index the document if the specified version is strictly higher than the version of the stored document or if there is no existing document.external_gte: Only index the document if the specified version is equal or higher than the version of the stored document or if there is no existing document. NOTE: Theexternal_gteversion type is meant for special use cases and should be used with care. If used incorrectly, it can result in loss of data.
-
Values:
internalexternalexternal_gte -
errorErrorCause -
typestringrequired -
The type of error
-
reasonstringnullable -
A human-readable explanation of the error, in English.
-
stack_tracestring -
The server stack trace. Present only if the
error_trace=trueparameter was sent with the request. -
caused_byErrorCause -
root_causeErrorCause -
suppressedErrorCause -
processor_resultsPipelineProcessorResult -
docDocumentSimulation -
tagstring -
processor_typestring -
statusPipelineSimulationStatusOptions -
Values:
successerrorerror_ignoredskippeddropped -
descriptionstring -
ignored_errorErrorCause -
typestringrequired -
The type of error
-
reasonstringnullable -
A human-readable explanation of the error, in English.
-
stack_tracestring -
The server stack trace. Present only if the
error_trace=trueparameter was sent with the request. -
caused_byErrorCause -
root_causeErrorCause -
suppressedErrorCause -
errorErrorCause -
typestringrequired -
The type of error
-
reasonstringnullable -
A human-readable explanation of the error, in English.
-
stack_tracestring -
The server stack trace. Present only if the
error_trace=trueparameter was sent with the request. -
caused_byErrorCause -
root_causeErrorCause -
suppressedErrorCause