1
0

stop-dfanalytics.asciidoc 2.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586
  1. [role="xpack"]
  2. [testenv="platinum"]
  3. [[stop-dfanalytics]]
  4. === Stop {dfanalytics-jobs} API
  5. [subs="attributes"]
  6. ++++
  7. <titleabbrev>Stop {dfanalytics-jobs}</titleabbrev>
  8. ++++
  9. Stops one or more {dfanalytics-jobs}.
  10. experimental[]
  11. [[ml-stop-dfanalytics-request]]
  12. ==== {api-request-title}
  13. `POST _ml/data_frame/analytics/<data_frame_analytics_id>/_stop` +
  14. `POST _ml/data_frame/analytics/<data_frame_analytics_id>,<data_frame_analytics_id>/_stop` +
  15. `POST _ml/data_frame/analytics/_all/_stop`
  16. [[ml-stop-dfanalytics-prereq]]
  17. ==== {api-prereq-title}
  18. * You must have `machine_learning_admin` built-in role to use this API. For more
  19. information, see {stack-ov}/security-privileges.html[Security privileges] and
  20. {stack-ov}/built-in-roles.html[Built-in roles].
  21. [[ml-stop-dfanalytics-desc]]
  22. ==== {api-description-title}
  23. A {dfanalytics-job} can be started and stopped multiple times throughout its
  24. lifecycle.
  25. You can stop multiple {dfanalytics-jobs} in a single API request by using a
  26. comma-separated list of {dfanalytics-jobs} or a wildcard expression. You can
  27. stop all {dfanalytics-job} by using _all or by specifying * as the
  28. <data_frame_analytics_id>.
  29. [[ml-stop-dfanalytics-path-params]]
  30. ==== {api-path-parms-title}
  31. `<data_frame_analytics_id>`::
  32. (Required, string) Identifier for the {dfanalytics-job}. This identifier can
  33. contain lowercase alphanumeric characters (a-z and 0-9), hyphens, and
  34. underscores. It must start and end with alphanumeric characters.
  35. [[ml-stop-dfanalytics-query-params]]
  36. ==== {api-query-parms-title}
  37. `allow_no_match`::
  38. (Optional, boolean) If `false` and the `data_frame_analytics_id` does not
  39. match any {dfanalytics-job} an error will be returned. The default value is
  40. `true`.
  41. `force`::
  42. (Optional, boolean) If true, the {dfanalytics-job} is stopped forcefully.
  43. `timeout`::
  44. (Optional, time) Controls the amount of time to wait until the
  45. {dfanalytics-job} stops. The default value is 20 seconds.
  46. [[ml-stop-dfanalytics-example]]
  47. ==== {api-examples-title}
  48. The following example stops the `loganalytics` {dfanalytics-job}:
  49. [source,js]
  50. --------------------------------------------------
  51. POST _ml/data_frame/analytics/loganalytics/_stop
  52. --------------------------------------------------
  53. // CONSOLE
  54. // TEST[skip:TBD]
  55. When the {dfanalytics-job} stops, you receive the following results:
  56. [source,js]
  57. ----
  58. {
  59. "stopped" : true
  60. }
  61. ----
  62. // TESTRESPONSE