2018-10-05 11:45:46 -04:00
|
|
|
--
|
|
|
|
:api: delete-forecast
|
|
|
|
:request: DeleteForecastRequest
|
|
|
|
:response: AcknowledgedResponse
|
|
|
|
--
|
2019-09-10 11:26:56 -04:00
|
|
|
[role="xpack"]
|
2018-10-05 11:45:46 -04:00
|
|
|
[id="{upid}-{api}"]
|
2018-09-11 19:32:52 -04:00
|
|
|
=== Delete Forecast API
|
|
|
|
|
|
|
|
The Delete Forecast API provides the ability to delete a {ml} job's
|
|
|
|
forecast in the cluster.
|
2018-10-05 11:45:46 -04:00
|
|
|
It accepts a +{request}+ object and responds
|
|
|
|
with an +{response}+ object.
|
2018-09-11 19:32:52 -04:00
|
|
|
|
2018-10-05 11:45:46 -04:00
|
|
|
[id="{upid}-{api}-request"]
|
2018-09-11 19:32:52 -04:00
|
|
|
==== Delete Forecast Request
|
|
|
|
|
2018-10-05 11:45:46 -04:00
|
|
|
A +{request}+ object gets created with an existing non-null `jobId`.
|
2018-09-11 19:32:52 -04:00
|
|
|
All other fields are optional for the request.
|
|
|
|
|
|
|
|
["source","java",subs="attributes,callouts,macros"]
|
|
|
|
--------------------------------------------------
|
2018-10-05 11:45:46 -04:00
|
|
|
include-tagged::{doc-tests-file}[{api}-request]
|
2018-09-11 19:32:52 -04:00
|
|
|
--------------------------------------------------
|
|
|
|
<1> Constructing a new request referencing an existing `jobId`
|
|
|
|
|
|
|
|
==== Optional Arguments
|
|
|
|
|
|
|
|
The following arguments are optional.
|
|
|
|
|
|
|
|
["source","java",subs="attributes,callouts,macros"]
|
|
|
|
--------------------------------------------------
|
2018-10-05 11:45:46 -04:00
|
|
|
include-tagged::{doc-tests-file}[{api}-request-options]
|
2018-09-11 19:32:52 -04:00
|
|
|
--------------------------------------------------
|
|
|
|
<1> Sets the specific forecastIds to delete, can be set to `_all` to indicate ALL forecasts for the given
|
|
|
|
`jobId`
|
|
|
|
<2> Set the timeout for the request to respond, default is 30 seconds
|
|
|
|
<3> Set the `allow_no_forecasts` option. When `true` no error will be returned if an `_all`
|
2018-10-05 11:45:46 -04:00
|
|
|
request finds no forecasts. It defaults to `true`
|
2018-09-11 19:32:52 -04:00
|
|
|
|
2018-10-05 11:45:46 -04:00
|
|
|
[id="{upid}-{api}-response"]
|
2018-09-11 19:32:52 -04:00
|
|
|
==== Delete Forecast Response
|
|
|
|
|
2018-10-05 11:45:46 -04:00
|
|
|
An +{response}+ contains an acknowledgement of the forecast(s) deletion
|
2018-09-11 19:32:52 -04:00
|
|
|
|
|
|
|
["source","java",subs="attributes,callouts,macros"]
|
|
|
|
--------------------------------------------------
|
2018-10-05 11:45:46 -04:00
|
|
|
include-tagged::{doc-tests-file}[{api}-response]
|
2018-09-11 19:32:52 -04:00
|
|
|
--------------------------------------------------
|
|
|
|
<1> `isAcknowledged()` indicates if the forecast was successfully deleted or not.
|
2018-10-05 11:45:46 -04:00
|
|
|
|
|
|
|
include::../execution.asciidoc[]
|