summaryrefslogtreecommitdiff
path: root/core/src/main/java/org/elasticsearch/rest/action/index/RestIndexAction.java
diff options
context:
space:
mode:
Diffstat (limited to 'core/src/main/java/org/elasticsearch/rest/action/index/RestIndexAction.java')
-rw-r--r--core/src/main/java/org/elasticsearch/rest/action/index/RestIndexAction.java5
1 files changed, 3 insertions, 2 deletions
diff --git a/core/src/main/java/org/elasticsearch/rest/action/index/RestIndexAction.java b/core/src/main/java/org/elasticsearch/rest/action/index/RestIndexAction.java
index 13a9329918..26dd1eca78 100644
--- a/core/src/main/java/org/elasticsearch/rest/action/index/RestIndexAction.java
+++ b/core/src/main/java/org/elasticsearch/rest/action/index/RestIndexAction.java
@@ -47,7 +47,7 @@ public class RestIndexAction extends BaseRestHandler {
@Inject
public RestIndexAction(Settings settings, RestController controller, Client client) {
- super(settings, controller, client);
+ super(settings, client);
controller.registerHandler(POST, "/{index}/{type}", this); // auto id creation
controller.registerHandler(PUT, "/{index}/{type}/{id}", this);
controller.registerHandler(POST, "/{index}/{type}/{id}", this);
@@ -58,7 +58,7 @@ public class RestIndexAction extends BaseRestHandler {
final class CreateHandler extends BaseRestHandler {
protected CreateHandler(Settings settings, RestController controller, Client client) {
- super(settings, controller, client);
+ super(settings, client);
}
@Override
@@ -77,6 +77,7 @@ public class RestIndexAction extends BaseRestHandler {
if (request.hasParam("ttl")) {
indexRequest.ttl(request.param("ttl"));
}
+ indexRequest.setPipeline(request.param("pipeline"));
indexRequest.source(request.content());
indexRequest.timeout(request.paramAsTime("timeout", IndexRequest.DEFAULT_TIMEOUT));
indexRequest.refresh(request.paramAsBoolean("refresh", indexRequest.refresh()));