diff --git a/client/rest-high-level/src/main/java/org/elasticsearch/client/IndexLifecycleRequestConverters.java b/client/rest-high-level/src/main/java/org/elasticsearch/client/IndexLifecycleRequestConverters.java index f61fac3323a..5e185866f8a 100644 --- a/client/rest-high-level/src/main/java/org/elasticsearch/client/IndexLifecycleRequestConverters.java +++ b/client/rest-high-level/src/main/java/org/elasticsearch/client/IndexLifecycleRequestConverters.java @@ -41,7 +41,7 @@ final class IndexLifecycleRequestConverters { private IndexLifecycleRequestConverters() {} static Request getLifecyclePolicy(GetLifecyclePolicyRequest getLifecyclePolicyRequest) { - String endpoint = new RequestConverters.EndpointBuilder().addPathPartAsIs("_ilm") + String endpoint = new RequestConverters.EndpointBuilder().addPathPartAsIs("_ilm/policy") .addCommaSeparatedPathParts(getLifecyclePolicyRequest.getPolicyNames()).build(); Request request = new Request(HttpGet.METHOD_NAME, endpoint); RequestConverters.Params params = new RequestConverters.Params(request); @@ -52,7 +52,7 @@ final class IndexLifecycleRequestConverters { static Request putLifecyclePolicy(PutLifecyclePolicyRequest putLifecycleRequest) throws IOException { String endpoint = new RequestConverters.EndpointBuilder() - .addPathPartAsIs("_ilm") + .addPathPartAsIs("_ilm/policy") .addPathPartAsIs(putLifecycleRequest.getName()) .build(); Request request = new Request(HttpPut.METHOD_NAME, endpoint); @@ -66,7 +66,7 @@ final class IndexLifecycleRequestConverters { static Request deleteLifecyclePolicy(DeleteLifecyclePolicyRequest deleteLifecyclePolicyRequest) { Request request = new Request(HttpDelete.METHOD_NAME, new RequestConverters.EndpointBuilder() - .addPathPartAsIs("_ilm") + .addPathPartAsIs("_ilm/policy") .addPathPartAsIs(deleteLifecyclePolicyRequest.getLifecyclePolicy()) .build()); RequestConverters.Params params = new RequestConverters.Params(request); diff --git a/client/rest-high-level/src/test/java/org/elasticsearch/client/IndexLifecycleRequestConvertersTests.java b/client/rest-high-level/src/test/java/org/elasticsearch/client/IndexLifecycleRequestConvertersTests.java index bc878f328ef..0030fd0773a 100644 --- a/client/rest-high-level/src/test/java/org/elasticsearch/client/IndexLifecycleRequestConvertersTests.java +++ b/client/rest-high-level/src/test/java/org/elasticsearch/client/IndexLifecycleRequestConvertersTests.java @@ -60,7 +60,7 @@ public class IndexLifecycleRequestConvertersTests extends ESTestCase { Request request = IndexLifecycleRequestConverters.getLifecyclePolicy(req); assertEquals(request.getMethod(), HttpGet.METHOD_NAME); String policiesStr = Strings.arrayToCommaDelimitedString(policies); - assertEquals(request.getEndpoint(), "/_ilm" + (policiesStr.isEmpty() ? "" : ("/" + policiesStr))); + assertEquals(request.getEndpoint(), "/_ilm/policy" + (policiesStr.isEmpty() ? "" : ("/" + policiesStr))); assertEquals(request.getParameters(), expectedParams); } @@ -74,7 +74,7 @@ public class IndexLifecycleRequestConvertersTests extends ESTestCase { Request request = IndexLifecycleRequestConverters.putLifecyclePolicy(req); assertEquals(HttpPut.METHOD_NAME, request.getMethod()); - assertEquals("/_ilm/" + name, request.getEndpoint()); + assertEquals("/_ilm/policy/" + name, request.getEndpoint()); assertEquals(expectedParams, request.getParameters()); } @@ -87,7 +87,7 @@ public class IndexLifecycleRequestConvertersTests extends ESTestCase { Request request = IndexLifecycleRequestConverters.deleteLifecyclePolicy(req); assertEquals(request.getMethod(), HttpDelete.METHOD_NAME); - assertEquals(request.getEndpoint(), "/_ilm/" + lifecycleName); + assertEquals(request.getEndpoint(), "/_ilm/policy/" + lifecycleName); assertEquals(request.getParameters(), expectedParams); } diff --git a/docs/reference/ilm/apis/delete-lifecycle.asciidoc b/docs/reference/ilm/apis/delete-lifecycle.asciidoc index 9adf2c0c3dc..3c8b6c397c0 100644 --- a/docs/reference/ilm/apis/delete-lifecycle.asciidoc +++ b/docs/reference/ilm/apis/delete-lifecycle.asciidoc @@ -10,7 +10,7 @@ Deletes an existing lifecycle policy ==== Request -`DELETE _ilm/` +`DELETE _ilm/policy/` ==== Description @@ -43,7 +43,7 @@ The following example deletes an existing policy named `my_policy`: [source,js] -------------------------------------------------- -PUT _ilm/my_policy +PUT _ilm/policy/my_policy { "policy": { "phases": { @@ -72,7 +72,7 @@ PUT _ilm/my_policy [source,js] -------------------------------------------------- -DELETE _ilm/my_policy +DELETE _ilm/policy/my_policy -------------------------------------------------- // CONSOLE // TEST[continued] diff --git a/docs/reference/ilm/apis/explain.asciidoc b/docs/reference/ilm/apis/explain.asciidoc index c15803b1dda..899f30d9c6c 100644 --- a/docs/reference/ilm/apis/explain.asciidoc +++ b/docs/reference/ilm/apis/explain.asciidoc @@ -47,7 +47,7 @@ The following example retrieves the lifecycle state for the index `my_index`: [source,js] -------------------------------------------------- -PUT _ilm/my_policy +PUT _ilm/policy/my_policy { "policy": { "phases": { diff --git a/docs/reference/ilm/apis/get-lifecycle.asciidoc b/docs/reference/ilm/apis/get-lifecycle.asciidoc index 5d20af24ab9..dbc8a572903 100644 --- a/docs/reference/ilm/apis/get-lifecycle.asciidoc +++ b/docs/reference/ilm/apis/get-lifecycle.asciidoc @@ -10,8 +10,8 @@ Retrieves an existing policy ==== Request -`GET _ilm` -`GET _ilm/` +`GET _ilm/policy` +`GET _ilm/policy/` ==== Description @@ -46,7 +46,7 @@ The following example retrieves the policy named `my_policy`: [source,js] -------------------------------------------------- -PUT _ilm/my_policy +PUT _ilm/policy/my_policy { "policy": { "phases": { @@ -75,7 +75,7 @@ PUT _ilm/my_policy [source,js] -------------------------------------------------- -GET _ilm +GET _ilm/policy -------------------------------------------------- // CONSOLE // TEST[continued] diff --git a/docs/reference/ilm/apis/move-to-step.asciidoc b/docs/reference/ilm/apis/move-to-step.asciidoc index f927c3ac4c8..c34b800856c 100644 --- a/docs/reference/ilm/apis/move-to-step.asciidoc +++ b/docs/reference/ilm/apis/move-to-step.asciidoc @@ -50,7 +50,7 @@ forcemerge step: [source,js] -------------------------------------------------- -PUT _ilm/my_policy +PUT _ilm/policy/my_policy { "policy": { "phases": { diff --git a/docs/reference/ilm/apis/put-lifecycle.asciidoc b/docs/reference/ilm/apis/put-lifecycle.asciidoc index 9ac7d956c34..36650078db6 100644 --- a/docs/reference/ilm/apis/put-lifecycle.asciidoc +++ b/docs/reference/ilm/apis/put-lifecycle.asciidoc @@ -10,7 +10,7 @@ Creates or updates an ILM Policy ==== Request -`PUT _ilm/` +`PUT _ilm/policy/` ==== Description @@ -46,7 +46,7 @@ The following example creates a new policy named `my_policy`: [source,js] -------------------------------------------------- -PUT _ilm/my_policy +PUT _ilm/policy/my_policy { "policy": { "phases": { diff --git a/docs/reference/ilm/apis/remove-policy.asciidoc b/docs/reference/ilm/apis/remove-policy.asciidoc index 1fab265ede9..8ee313f4e30 100644 --- a/docs/reference/ilm/apis/remove-policy.asciidoc +++ b/docs/reference/ilm/apis/remove-policy.asciidoc @@ -44,7 +44,7 @@ The following example removes a policy `my_policy` from an index `my_index`. [source,js] -------------------------------------------------- -PUT _ilm/my_policy +PUT _ilm/policy/my_policy { "policy": { "phases": { diff --git a/docs/reference/ilm/apis/start.asciidoc b/docs/reference/ilm/apis/start.asciidoc index a1c112da77c..073a584e4d8 100644 --- a/docs/reference/ilm/apis/start.asciidoc +++ b/docs/reference/ilm/apis/start.asciidoc @@ -40,7 +40,7 @@ The following example starts the ILM plugin. [source,js] -------------------------------------------------- -PUT _ilm/my_policy +PUT _ilm/policy/my_policy { "policy": { "phases": { diff --git a/docs/reference/ilm/apis/stop.asciidoc b/docs/reference/ilm/apis/stop.asciidoc index ced79bcd434..cdc038adabc 100644 --- a/docs/reference/ilm/apis/stop.asciidoc +++ b/docs/reference/ilm/apis/stop.asciidoc @@ -42,7 +42,7 @@ The following example stops the ILM plugin. [source,js] -------------------------------------------------- -PUT _ilm/my_policy +PUT _ilm/policy/my_policy { "policy": { "phases": { diff --git a/docs/reference/ilm/set-up-lifecycle-policy.asciidoc b/docs/reference/ilm/set-up-lifecycle-policy.asciidoc index cdc24ae8d56..7f5bb84c598 100644 --- a/docs/reference/ilm/set-up-lifecycle-policy.asciidoc +++ b/docs/reference/ilm/set-up-lifecycle-policy.asciidoc @@ -10,7 +10,7 @@ our indexes. [source,js] ------------------------ -PUT _ilm/my_policy +PUT _ilm/policy/my_policy { "policy": { "phases": { diff --git a/docs/reference/ilm/start-stop-ilm.asciidoc b/docs/reference/ilm/start-stop-ilm.asciidoc index 816c5581956..938b97d4472 100644 --- a/docs/reference/ilm/start-stop-ilm.asciidoc +++ b/docs/reference/ilm/start-stop-ilm.asciidoc @@ -17,7 +17,7 @@ to see the current state of ILM. //// [source,js] -------------------------------------------------- -PUT _ilm/my_policy +PUT _ilm/policy/my_policy { "policy": { "phases": { diff --git a/docs/reference/ilm/update-lifecycle-policy.asciidoc b/docs/reference/ilm/update-lifecycle-policy.asciidoc index 1fc02cac1f5..1711b097964 100644 --- a/docs/reference/ilm/update-lifecycle-policy.asciidoc +++ b/docs/reference/ilm/update-lifecycle-policy.asciidoc @@ -21,7 +21,7 @@ To show this, let's create a policy `my_policy`. [source,js] ------------------------ -PUT _ilm/my_policy +PUT _ilm/policy/my_policy { "policy": { "phases": { @@ -53,7 +53,7 @@ Updating the Delete phase's minimum age can be done in an update request. [source,js] ------------------------ -PUT _ilm/my_policy +PUT _ilm/policy/my_policy { "policy": { "phases": { @@ -81,7 +81,7 @@ PUT _ilm/my_policy ////////// [source,js] -------------------------------------------------- -GET _ilm +GET _ilm/policy -------------------------------------------------- // CONSOLE // TEST[continued] @@ -136,7 +136,7 @@ Let's say we have an index `my_index` managed by the below `my_executing_policy` [source,js] ------------------------ -PUT _ilm/my_executing_policy +PUT _ilm/policy/my_executing_policy { "policy": { "phases": { @@ -226,7 +226,7 @@ Updating `my_executing_policy` to have no rollover action and, instead, go direc [source,js] ------------------------ -PUT _ilm/my_executing_policy +PUT _ilm/policy/my_executing_policy { "policy": { "phases": { @@ -371,7 +371,7 @@ it will move on to the next phase in `my_other_policy`. So if it was on the //// [source,js] ------------------------ -PUT _ilm/my_policy +PUT _ilm/policy/my_policy { "policy": { "phases": { @@ -392,7 +392,7 @@ PUT _ilm/my_policy } } -PUT _ilm/my_other_policy +PUT _ilm/policy/my_other_policy { "policy": { "phases": { diff --git a/docs/reference/ilm/using-policies-rollover.asciidoc b/docs/reference/ilm/using-policies-rollover.asciidoc index 327dbe07f94..f7982af4fec 100644 --- a/docs/reference/ilm/using-policies-rollover.asciidoc +++ b/docs/reference/ilm/using-policies-rollover.asciidoc @@ -48,7 +48,7 @@ this example, that means the index will be deleted 30 days after rollover, not [source,js] -------------------------------------------------- -PUT /_ilm/my_policy +PUT /_ilm/policy/my_policy { "policy": { "phases": { diff --git a/test/framework/src/main/java/org/elasticsearch/test/rest/ESRestTestCase.java b/test/framework/src/main/java/org/elasticsearch/test/rest/ESRestTestCase.java index 8de3ef01713..7f2caa06c8e 100644 --- a/test/framework/src/main/java/org/elasticsearch/test/rest/ESRestTestCase.java +++ b/test/framework/src/main/java/org/elasticsearch/test/rest/ESRestTestCase.java @@ -526,10 +526,10 @@ public abstract class ESRestTestCase extends ESTestCase { Map policies; try { - Response response = adminClient().performRequest(new Request("GET", "/_ilm")); + Response response = adminClient().performRequest(new Request("GET", "/_ilm/policy")); policies = entityAsMap(response); } catch (ResponseException e) { - if (RestStatus.BAD_REQUEST.getStatus() == e.getResponse().getStatusLine().getStatusCode()) { + if (RestStatus.METHOD_NOT_ALLOWED.getStatus() == e.getResponse().getStatusLine().getStatusCode()) { // If bad request returned, ILM is not enabled. return; } @@ -541,7 +541,7 @@ public abstract class ESRestTestCase extends ESTestCase { } for (String policyName : policies.keySet()) { - adminClient().performRequest(new Request("DELETE", "/_ilm/" + policyName)); + adminClient().performRequest(new Request("DELETE", "/_ilm/policy/" + policyName)); } } diff --git a/x-pack/plugin/ilm/qa/multi-node/src/test/java/org/elasticsearch/xpack/indexlifecycle/TimeSeriesLifecycleActionsIT.java b/x-pack/plugin/ilm/qa/multi-node/src/test/java/org/elasticsearch/xpack/indexlifecycle/TimeSeriesLifecycleActionsIT.java index 3b455a2287d..c06b30cf575 100644 --- a/x-pack/plugin/ilm/qa/multi-node/src/test/java/org/elasticsearch/xpack/indexlifecycle/TimeSeriesLifecycleActionsIT.java +++ b/x-pack/plugin/ilm/qa/multi-node/src/test/java/org/elasticsearch/xpack/indexlifecycle/TimeSeriesLifecycleActionsIT.java @@ -363,7 +363,7 @@ public class TimeSeriesLifecycleActionsIT extends ESRestTestCase { lifecyclePolicy.toXContent(builder, null); final StringEntity entity = new StringEntity( "{ \"policy\":" + Strings.toString(builder) + "}", ContentType.APPLICATION_JSON); - Request request = new Request("PUT", "_ilm/" + policy); + Request request = new Request("PUT", "_ilm/policy/" + policy); request.setEntity(entity); assertOK(client().performRequest(request)); } @@ -379,7 +379,7 @@ public class TimeSeriesLifecycleActionsIT extends ESRestTestCase { lifecyclePolicy.toXContent(builder, null); final StringEntity entity = new StringEntity( "{ \"policy\":" + Strings.toString(builder) + "}", ContentType.APPLICATION_JSON); - Request request = new Request("PUT", "_ilm/" + policy); + Request request = new Request("PUT", "_ilm/policy/" + policy); request.setEntity(entity); client().performRequest(request); } diff --git a/x-pack/plugin/ilm/qa/with-security/src/test/java/org/elasticsearch/xpack/security/PermissionsIT.java b/x-pack/plugin/ilm/qa/with-security/src/test/java/org/elasticsearch/xpack/security/PermissionsIT.java index 1aa8f0db950..01eb07bb35b 100644 --- a/x-pack/plugin/ilm/qa/with-security/src/test/java/org/elasticsearch/xpack/security/PermissionsIT.java +++ b/x-pack/plugin/ilm/qa/with-security/src/test/java/org/elasticsearch/xpack/security/PermissionsIT.java @@ -126,7 +126,7 @@ public class PermissionsIT extends ESRestTestCase { lifecyclePolicy.toXContent(builder, null); final StringEntity entity = new StringEntity( "{ \"policy\":" + Strings.toString(builder) + "}", ContentType.APPLICATION_JSON); - Request request = new Request("PUT", "_ilm/" + policy); + Request request = new Request("PUT", "_ilm/policy/" + policy); request.setEntity(entity); client().performRequest(request); } diff --git a/x-pack/plugin/ilm/src/main/java/org/elasticsearch/xpack/indexlifecycle/action/RestDeleteLifecycleAction.java b/x-pack/plugin/ilm/src/main/java/org/elasticsearch/xpack/indexlifecycle/action/RestDeleteLifecycleAction.java index 3c001e6951e..081e7d1565f 100644 --- a/x-pack/plugin/ilm/src/main/java/org/elasticsearch/xpack/indexlifecycle/action/RestDeleteLifecycleAction.java +++ b/x-pack/plugin/ilm/src/main/java/org/elasticsearch/xpack/indexlifecycle/action/RestDeleteLifecycleAction.java @@ -20,7 +20,7 @@ public class RestDeleteLifecycleAction extends BaseRestHandler { public RestDeleteLifecycleAction(Settings settings, RestController controller) { super(settings); - controller.registerHandler(RestRequest.Method.DELETE, "/_ilm/{name}", this); + controller.registerHandler(RestRequest.Method.DELETE, "/_ilm/policy/{name}", this); } @Override @@ -37,4 +37,4 @@ public class RestDeleteLifecycleAction extends BaseRestHandler { return channel -> client.execute(DeleteLifecycleAction.INSTANCE, deleteLifecycleRequest, new RestToXContentListener<>(channel)); } -} \ No newline at end of file +} diff --git a/x-pack/plugin/ilm/src/main/java/org/elasticsearch/xpack/indexlifecycle/action/RestGetLifecycleAction.java b/x-pack/plugin/ilm/src/main/java/org/elasticsearch/xpack/indexlifecycle/action/RestGetLifecycleAction.java index 9d0ae98b47e..b518fe2f086 100644 --- a/x-pack/plugin/ilm/src/main/java/org/elasticsearch/xpack/indexlifecycle/action/RestGetLifecycleAction.java +++ b/x-pack/plugin/ilm/src/main/java/org/elasticsearch/xpack/indexlifecycle/action/RestGetLifecycleAction.java @@ -21,8 +21,8 @@ public class RestGetLifecycleAction extends BaseRestHandler { public RestGetLifecycleAction(Settings settings, RestController controller) { super(settings); - controller.registerHandler(RestRequest.Method.GET, "/_ilm", this); - controller.registerHandler(RestRequest.Method.GET, "/_ilm/{name}", this); + controller.registerHandler(RestRequest.Method.GET, "/_ilm/policy", this); + controller.registerHandler(RestRequest.Method.GET, "/_ilm/policy/{name}", this); } @Override @@ -39,4 +39,4 @@ public class RestGetLifecycleAction extends BaseRestHandler { return channel -> client.execute(GetLifecycleAction.INSTANCE, getLifecycleRequest, new RestToXContentListener<>(channel)); } -} \ No newline at end of file +} diff --git a/x-pack/plugin/ilm/src/main/java/org/elasticsearch/xpack/indexlifecycle/action/RestPutLifecycleAction.java b/x-pack/plugin/ilm/src/main/java/org/elasticsearch/xpack/indexlifecycle/action/RestPutLifecycleAction.java index 6766ce65cad..586c3c68326 100644 --- a/x-pack/plugin/ilm/src/main/java/org/elasticsearch/xpack/indexlifecycle/action/RestPutLifecycleAction.java +++ b/x-pack/plugin/ilm/src/main/java/org/elasticsearch/xpack/indexlifecycle/action/RestPutLifecycleAction.java @@ -21,7 +21,7 @@ public class RestPutLifecycleAction extends BaseRestHandler { public RestPutLifecycleAction(Settings settings, RestController controller) { super(settings); - controller.registerHandler(RestRequest.Method.PUT, "/_ilm/{name}", this); + controller.registerHandler(RestRequest.Method.PUT, "/_ilm/policy/{name}", this); } @Override @@ -39,4 +39,4 @@ public class RestPutLifecycleAction extends BaseRestHandler { return channel -> client.execute(PutLifecycleAction.INSTANCE, putLifecycleRequest, new RestToXContentListener<>(channel)); } -} \ No newline at end of file +} diff --git a/x-pack/plugin/ilm/src/test/java/org/elasticsearch/xpack/indexlifecycle/ChangePolicyforIndexIT.java b/x-pack/plugin/ilm/src/test/java/org/elasticsearch/xpack/indexlifecycle/ChangePolicyforIndexIT.java index 83622b51170..c0775c9e518 100644 --- a/x-pack/plugin/ilm/src/test/java/org/elasticsearch/xpack/indexlifecycle/ChangePolicyforIndexIT.java +++ b/x-pack/plugin/ilm/src/test/java/org/elasticsearch/xpack/indexlifecycle/ChangePolicyforIndexIT.java @@ -39,7 +39,7 @@ public class ChangePolicyforIndexIT extends ESRestTestCase { * existing definition when the policy is changed for that index, and that * after completing the current phase the new policy will be used for * subsequent phases. - * + * * The test creates two policies, one with a hot phase requiring 1 document * to rollover and a warm phase with an impossible allocation action. The * second policy has a rollover action requiring 1000 document and a warm @@ -69,13 +69,13 @@ public class ChangePolicyforIndexIT extends ESRestTestCase { XContentBuilder builder1 = jsonBuilder(); lifecyclePolicy1.toXContent(builder1, null); final StringEntity entity1 = new StringEntity("{ \"policy\":" + Strings.toString(builder1) + "}", ContentType.APPLICATION_JSON); - Request request1 = new Request("PUT", "_ilm/" + "policy_1"); + Request request1 = new Request("PUT", "_ilm/policy/" + "policy_1"); request1.setEntity(entity1); assertOK(client().performRequest(request1)); XContentBuilder builder2 = jsonBuilder(); lifecyclePolicy2.toXContent(builder2, null); final StringEntity entity2 = new StringEntity("{ \"policy\":" + Strings.toString(builder2) + "}", ContentType.APPLICATION_JSON); - Request request2 = new Request("PUT", "_ilm/" + "policy_2"); + Request request2 = new Request("PUT", "_ilm/policy/" + "policy_2"); request2.setEntity(entity2); assertOK(client().performRequest(request2)); diff --git a/x-pack/plugin/src/test/resources/rest-api-spec/api/ilm.delete_lifecycle.json b/x-pack/plugin/src/test/resources/rest-api-spec/api/ilm.delete_lifecycle.json index 6469cd4a977..4deaaaffc15 100644 --- a/x-pack/plugin/src/test/resources/rest-api-spec/api/ilm.delete_lifecycle.json +++ b/x-pack/plugin/src/test/resources/rest-api-spec/api/ilm.delete_lifecycle.json @@ -3,8 +3,8 @@ "documentation": "http://www.elastic.co/guide/en/index_lifecycle/current/index_lifecycle.html", "methods": [ "DELETE" ], "url": { - "path": "/_ilm/{policy}", - "paths": ["/_ilm/{policy}"], + "path": "/_ilm/policy/{policy}", + "paths": ["/_ilm/policy/{policy}"], "parts": { "policy": { "type" : "string", diff --git a/x-pack/plugin/src/test/resources/rest-api-spec/api/ilm.get_lifecycle.json b/x-pack/plugin/src/test/resources/rest-api-spec/api/ilm.get_lifecycle.json index c79c1a89c6a..9fbabb96479 100644 --- a/x-pack/plugin/src/test/resources/rest-api-spec/api/ilm.get_lifecycle.json +++ b/x-pack/plugin/src/test/resources/rest-api-spec/api/ilm.get_lifecycle.json @@ -3,8 +3,8 @@ "documentation": "http://www.elastic.co/guide/en/index_lifecycle/current/index_lifecycle.html", "methods": [ "GET" ], "url": { - "path": "/_ilm/{policy}", - "paths": ["/_ilm/{policy}", "/_ilm"], + "path": "/_ilm/policy/{policy}", + "paths": ["/_ilm/policy/{policy}", "/_ilm/policy"], "parts": { "policy": { "type" : "string", diff --git a/x-pack/plugin/src/test/resources/rest-api-spec/api/ilm.put_lifecycle.json b/x-pack/plugin/src/test/resources/rest-api-spec/api/ilm.put_lifecycle.json index 1c1187475ef..f23b3b3eb15 100644 --- a/x-pack/plugin/src/test/resources/rest-api-spec/api/ilm.put_lifecycle.json +++ b/x-pack/plugin/src/test/resources/rest-api-spec/api/ilm.put_lifecycle.json @@ -3,8 +3,8 @@ "documentation": "http://www.elastic.co/guide/en/index_lifecycle/current/index_lifecycle.html", "methods": [ "PUT" ], "url": { - "path": "/_ilm/{policy}", - "paths": ["/_ilm/{policy}"], + "path": "/_ilm/policy/{policy}", + "paths": ["/_ilm/policy/{policy}"], "parts": { "policy": { "type" : "string",