open-job.asciidoc 1.1 KB

123456789101112131415161718192021222324252627282930313233343536
  1. --
  2. :api: open-job
  3. :request: OpenJobRequest
  4. :response: OpenJobResponse
  5. --
  6. [role="xpack"]
  7. [id="{upid}-{api}"]
  8. === Open {anomaly-job} API
  9. Opens {anomaly-jobs} in the cluster. It accepts a +{request}+ object and
  10. responds with a +{response}+ object.
  11. [id="{upid}-{api}-request"]
  12. ==== Open {anomaly-job} request
  13. An +{request}+ object gets created with an existing non-null `jobId`.
  14. ["source","java",subs="attributes,callouts,macros"]
  15. --------------------------------------------------
  16. include-tagged::{doc-tests-file}[{api}-request]
  17. --------------------------------------------------
  18. <1> Constructing a new request referencing an existing `jobId`
  19. <2> Optionally setting the `timeout` value for how long the
  20. execution should wait for the job to be opened.
  21. [id="{upid}-{api}-response"]
  22. ==== Open {anomaly-job} response
  23. ["source","java",subs="attributes,callouts,macros"]
  24. --------------------------------------------------
  25. include-tagged::{doc-tests-file}[{api}-response]
  26. --------------------------------------------------
  27. <1> `isOpened()` from the +{response}+ indicates if the job was successfully
  28. opened or not.
  29. include::../execution.asciidoc[]