Watcher: Fix acknowledgement REST API endpoints
Add new REST API endpoint to acknoweldging actions. The old endpoints have not been removed as part of this PR, but can be in the next major version. Update the documentation to remove the parameter based example, and mention that the old endpoints are going to be removed in the future. Closes elastic/elasticsearch#2517 Original commit: elastic/x-pack-elasticsearch@e2558e9e1f
This commit is contained in:
parent
6ed9f50457
commit
f78f848681
|
@ -33,6 +33,9 @@ public class RestAckWatchAction extends WatcherRestHandler {
|
|||
super(settings, client);
|
||||
controller.registerHandler(RestRequest.Method.PUT, URI_BASE + "/watch/{id}/_ack", this);
|
||||
controller.registerHandler(RestRequest.Method.POST, URI_BASE + "/watch/{id}/_ack", this);
|
||||
controller.registerHandler(RestRequest.Method.POST, URI_BASE + "/watch/{id}/_ack/{actions}", this);
|
||||
controller.registerHandler(RestRequest.Method.PUT, URI_BASE + "/watch/{id}/_ack/{actions}", this);
|
||||
// these are going to be removed in 6.0
|
||||
controller.registerHandler(RestRequest.Method.PUT, URI_BASE + "/watch/{id}/{actions}/_ack", this);
|
||||
controller.registerHandler(RestRequest.Method.POST, URI_BASE + "/watch/{id}/{actions}/_ack", this);
|
||||
}
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
"methods": [ "PUT", "POST" ],
|
||||
"url": {
|
||||
"path": "/_xpack/watcher/watch/{watch_id}/_ack",
|
||||
"paths": [ "/_xpack/watcher/watch/{watch_id}/_ack", "/_xpack/watcher/watch/{watch_id}/{action_id}/_ack"],
|
||||
"paths": [ "/_xpack/watcher/watch/{watch_id}/_ack", "/_xpack/watcher/watch/{watch_id}/_ack/{action_id}"],
|
||||
"parts": {
|
||||
"watch_id": {
|
||||
"type" : "string",
|
||||
|
|
Loading…
Reference in New Issue