Skip to content

Commit 6a9ebae

Browse files
CR: Force the _none pipeline on all requests that have a null pipeline set
1 parent b6d3ecb commit 6a9ebae

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

server/src/main/java/org/elasticsearch/action/bulk/TransportBulkAction.java

+4-2
Original file line numberDiff line numberDiff line change
@@ -135,10 +135,12 @@ protected void doExecute(Task task, BulkRequest bulkRequest, ActionListener<Bulk
135135
String pipeline = indexRequest.getPipeline();
136136
if (pipeline == null) {
137137
IndexMetaData indexMetaData = indicesMetaData.get(indexRequest.index());
138-
if (indexMetaData != null) {
138+
if (indexMetaData == null) {
139+
indexRequest.setPipeline(IngestService.NOOP_PIPELINE_NAME);
140+
} else {
139141
String defaultPipeline = IndexSettings.DEFAULT_PIPELINE.get(indexMetaData.getSettings());
142+
indexRequest.setPipeline(defaultPipeline);
140143
if (IngestService.NOOP_PIPELINE_NAME.equals(defaultPipeline) == false) {
141-
indexRequest.setPipeline(defaultPipeline);
142144
hasIndexRequestsWithPipelines = true;
143145
}
144146
}

0 commit comments

Comments
 (0)