get-datafeed-stats.asciidoc 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. --
  2. :api: get-datafeed-stats
  3. :request: GetDatafeedStatsRequest
  4. :response: GetDatafeedStatsResponse
  5. --
  6. [role="xpack"]
  7. [id="{upid}-{api}"]
  8. === Get datafeed stats API
  9. Retrieves any number of {ml} datafeeds' statistics in the cluster.
  10. It accepts a +{request}+ object and responds with a +{response}+ object.
  11. [id="{upid}-{api}-request"]
  12. ==== Get datafeed stats request
  13. A +{request}+ object can have any number of `datafeedId` entries. However, they
  14. all must be non-null. An empty list is the same as requesting statistics for all
  15. datafeeds.
  16. ["source","java",subs="attributes,callouts,macros"]
  17. --------------------------------------------------
  18. include-tagged::{doc-tests-file}[{api}-request]
  19. --------------------------------------------------
  20. <1> Constructing a new request referencing existing `datafeedIds`. It can
  21. contain wildcards.
  22. <2> Whether to ignore if a wildcard expression matches no datafeeds.
  23. (This includes `_all` string or when no datafeeds have been specified).
  24. include::../execution.asciidoc[]
  25. [id="{upid}-{api}-response"]
  26. ==== Get datafeed stats response
  27. The returned +{response}+ contains the requested datafeed statistics:
  28. ["source","java",subs="attributes,callouts,macros"]
  29. --------------------------------------------------
  30. include-tagged::{doc-tests-file}[{api}-response]
  31. --------------------------------------------------
  32. <1> `count()` indicates the number of datafeeds statistics found.
  33. <2> `datafeedStats()` is the collection of {ml} `DatafeedStats` objects found.