anomaly-detectors.asciidoc 9.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280
  1. [role="xpack"]
  2. [testenv="platinum"]
  3. [[cat-anomaly-detectors]]
  4. === cat anomaly detectors API
  5. ++++
  6. <titleabbrev>cat anomaly detectors</titleabbrev>
  7. ++++
  8. Returns configuration and usage information about {anomaly-jobs}.
  9. [[cat-anomaly-detectors-request]]
  10. ==== {api-request-title}
  11. `GET /_cat/ml/anomaly_detectors/<job_id>` +
  12. `GET /_cat/ml/anomaly_detectors`
  13. [[cat-anomaly-detectors-prereqs]]
  14. ==== {api-prereq-title}
  15. * If the {es} {security-features} are enabled, you must have `monitor_ml`,
  16. `monitor`, `manage_ml`, or `manage` cluster privileges to use this API. See
  17. <<security-privileges>> and {ml-docs}/setup.html[Set up {ml-features}].
  18. [[cat-anomaly-detectors-desc]]
  19. ==== {api-description-title}
  20. See {ml-docs}/ml-jobs.html[{anomaly-jobs-cap}].
  21. NOTE: This API returns a maximum of 10,000 jobs.
  22. [[cat-anomaly-detectors-path-params]]
  23. ==== {api-path-parms-title}
  24. `<job_id>`::
  25. (Optional, string)
  26. include::{docdir}/ml/ml-shared.asciidoc[tag=job-id-anomaly-detection]
  27. [[cat-anomaly-detectors-query-params]]
  28. ==== {api-query-parms-title}
  29. `allow_no_jobs`::
  30. (Optional, boolean)
  31. include::{docdir}/ml/ml-shared.asciidoc[tag=allow-no-jobs]
  32. include::{docdir}/rest-api/common-parms.asciidoc[tag=bytes]
  33. include::{docdir}/rest-api/common-parms.asciidoc[tag=http-format]
  34. include::{docdir}/rest-api/common-parms.asciidoc[tag=cat-h]
  35. +
  36. If you do not specify which columns to include, the API returns the default
  37. columns. If you explicitly specify one or more columns, it returns only the
  38. specified columns.
  39. +
  40. Valid columns are:
  41. `assignment_explanation`, `ae`:::
  42. include::{docdir}/ml/ml-shared.asciidoc[tag=assignment-explanation-anomaly-jobs]
  43. `buckets.count`, `bc`, `bucketsCount`:::
  44. (Default)
  45. include::{docdir}/ml/ml-shared.asciidoc[tag=bucket-count-anomaly-jobs]
  46. `buckets.time.exp_avg`, `btea`, `bucketsTimeExpAvg`:::
  47. include::{docdir}/ml/ml-shared.asciidoc[tag=bucket-time-exponential-average]
  48. `buckets.time.exp_avg_hour`, `bteah`, `bucketsTimeExpAvgHour`:::
  49. include::{docdir}/ml/ml-shared.asciidoc[tag=bucket-time-exponential-average-hour]
  50. `buckets.time.max`, `btmax`, `bucketsTimeMax`:::
  51. include::{docdir}/ml/ml-shared.asciidoc[tag=bucket-time-maximum]
  52. `buckets.time.min`, `btmin`, `bucketsTimeMin`:::
  53. include::{docdir}/ml/ml-shared.asciidoc[tag=bucket-time-minimum]
  54. `buckets.time.total`, `btt`, `bucketsTimeTotal`:::
  55. include::{docdir}/ml/ml-shared.asciidoc[tag=bucket-time-total]
  56. `data.buckets`, `db`, `dataBuckets`:::
  57. include::{docdir}/ml/ml-shared.asciidoc[tag=bucket-count]
  58. `data.earliest_record`, `der`, `dataEarliestRecord`:::
  59. include::{docdir}/ml/ml-shared.asciidoc[tag=earliest-record-timestamp]
  60. `data.empty_buckets`, `deb`, `dataEmptyBuckets`:::
  61. include::{docdir}/ml/ml-shared.asciidoc[tag=empty-bucket-count]
  62. `data.input_bytes`, `dib`, `dataInputBytes`:::
  63. include::{docdir}/ml/ml-shared.asciidoc[tag=input-bytes]
  64. `data.input_fields`, `dif`, `dataInputFields`:::
  65. include::{docdir}/ml/ml-shared.asciidoc[tag=input-field-count]
  66. `data.input_records`, `dir`, `dataInputRecords`:::
  67. include::{docdir}/ml/ml-shared.asciidoc[tag=input-record-count]
  68. `data.invalid_dates`, `did`, `dataInvalidDates`:::
  69. include::{docdir}/ml/ml-shared.asciidoc[tag=invalid-date-count]
  70. `data.last`, `dl`, `dataLast`:::
  71. include::{docdir}/ml/ml-shared.asciidoc[tag=last-data-time]
  72. `data.last_empty_bucket`, `dleb`, `dataLastEmptyBucket`:::
  73. include::{docdir}/ml/ml-shared.asciidoc[tag=latest-empty-bucket-timestamp]
  74. `data.last_sparse_bucket`, `dlsb`, `dataLastSparseBucket`:::
  75. include::{docdir}/ml/ml-shared.asciidoc[tag=latest-sparse-record-timestamp]
  76. `data.latest_record`, `dlr`, `dataLatestRecord`:::
  77. include::{docdir}/ml/ml-shared.asciidoc[tag=latest-record-timestamp]
  78. `data.missing_fields`, `dmf`, `dataMissingFields`:::
  79. include::{docdir}/ml/ml-shared.asciidoc[tag=missing-field-count]
  80. `data.out_of_order_timestamps`, `doot`, `dataOutOfOrderTimestamps`:::
  81. include::{docdir}/ml/ml-shared.asciidoc[tag=out-of-order-timestamp-count]
  82. `data.processed_fields`, `dpf`, `dataProcessedFields`:::
  83. include::{docdir}/ml/ml-shared.asciidoc[tag=processed-field-count]
  84. `data.processed_records`, `dpr`, `dataProcessedRecords`:::
  85. (Default)
  86. include::{docdir}/ml/ml-shared.asciidoc[tag=processed-record-count]
  87. `data.sparse_buckets`, `dsb`, `dataSparseBuckets`:::
  88. include::{docdir}/ml/ml-shared.asciidoc[tag=sparse-bucket-count]
  89. `forecasts.memory.avg`, `fmavg`, `forecastsMemoryAvg`:::
  90. The average memory usage in bytes for forecasts related to the {anomaly-job}.
  91. `forecasts.memory.max`, `fmmax`, `forecastsMemoryMax`:::
  92. The maximum memory usage in bytes for forecasts related to the {anomaly-job}.
  93. `forecasts.memory.min`, `fmmin`, `forecastsMemoryMin`:::
  94. The minimum memory usage in bytes for forecasts related to the {anomaly-job}.
  95. `forecasts.memory.total`, `fmt`, `forecastsMemoryTotal`:::
  96. The total memory usage in bytes for forecasts related to the {anomaly-job}.
  97. `forecasts.records.avg`, `fravg`, `forecastsRecordsAvg`:::
  98. The average number of `model_forecast` documents written for forecasts related
  99. to the {anomaly-job}.
  100. `forecasts.records.max`, `frmax`, `forecastsRecordsMax`:::
  101. The maximum number of `model_forecast` documents written for forecasts related
  102. to the {anomaly-job}.
  103. `forecasts.records.min`, `frmin`, `forecastsRecordsMin`:::
  104. The minimum number of `model_forecast` documents written for forecasts related
  105. to the {anomaly-job}.
  106. `forecasts.records.total`, `frt`, `forecastsRecordsTotal`:::
  107. The total number of `model_forecast` documents written for forecasts related to
  108. the {anomaly-job}.
  109. `forecasts.time.avg`, `ftavg`, `forecastsTimeAvg`:::
  110. The average runtime in milliseconds for forecasts related to the {anomaly-job}.
  111. `forecasts.time.max`, `ftmax`, `forecastsTimeMax`:::
  112. The maximum runtime in milliseconds for forecasts related to the {anomaly-job}.
  113. `forecasts.time.min`, `ftmin`, `forecastsTimeMin`:::
  114. The minimum runtime in milliseconds for forecasts related to the {anomaly-job}.
  115. `forecasts.time.total`, `ftt`, `forecastsTimeTotal`:::
  116. The total runtime in milliseconds for forecasts related to the {anomaly-job}.
  117. `forecasts.total`, `ft`, `forecastsTotal`:::
  118. (Default)
  119. include::{docdir}/ml/ml-shared.asciidoc[tag=forecast-total]
  120. `id`:::
  121. (Default)
  122. include::{docdir}/ml/ml-shared.asciidoc[tag=job-id-anomaly-detection]
  123. `model.bucket_allocation_failures`, `mbaf`, `modelBucketAllocationFailures`:::
  124. include::{docdir}/ml/ml-shared.asciidoc[tag=bucket-allocation-failures-count]
  125. `model.by_fields`, `mbf`, `modelByFields`:::
  126. include::{docdir}/ml/ml-shared.asciidoc[tag=total-by-field-count]
  127. `model.bytes`, `mb`, `modelBytes`:::
  128. (Default)
  129. include::{docdir}/ml/ml-shared.asciidoc[tag=model-bytes]
  130. `model.bytes_exceeded`, `mbe`, `modelBytesExceeded`:::
  131. include::{docdir}/ml/ml-shared.asciidoc[tag=model-bytes-exceeded]
  132. `model.categorization_status`, `mcs`, `modelCategorizationStatus`:::
  133. include::{docdir}/ml/ml-shared.asciidoc[tag=categorization-status]
  134. `model.categorized_doc_count`, `mcdc`, `modelCategorizedDocCount`:::
  135. include::{docdir}/ml/ml-shared.asciidoc[tag=categorized-doc-count]
  136. `model.dead_category_count`, `mdcc`, `modelDeadCategoryCount`:::
  137. include::{docdir}/ml/ml-shared.asciidoc[tag=dead-category-count]
  138. `model.frequent_category_count`, `mfcc`, `modelFrequentCategoryCount`:::
  139. include::{docdir}/ml/ml-shared.asciidoc[tag=frequent-category-count]
  140. `model.log_time`, `mlt`, `modelLogTime`:::
  141. The timestamp when the model stats were gathered, according to server time.
  142. `model.memory_limit`, `mml`, `modelMemoryLimit`:::
  143. include::{docdir}/ml/ml-shared.asciidoc[tag=model-memory-limit-anomaly-jobs]
  144. `model.memory_status`, `mms`, `modelMemoryStatus`:::
  145. (Default)
  146. include::{docdir}/ml/ml-shared.asciidoc[tag=model-memory-status]
  147. `model.over_fields`, `mof`, `modelOverFields`:::
  148. include::{docdir}/ml/ml-shared.asciidoc[tag=total-over-field-count]
  149. `model.partition_fields`, `mpf`, `modelPartitionFields`:::
  150. include::{docdir}/ml/ml-shared.asciidoc[tag=total-partition-field-count]
  151. `model.rare_category_count`, `mrcc`, `modelRareCategoryCount`:::
  152. include::{docdir}/ml/ml-shared.asciidoc[tag=rare-category-count]
  153. `model.timestamp`, `mt`, `modelTimestamp`:::
  154. include::{docdir}/ml/ml-shared.asciidoc[tag=model-timestamp]
  155. `model.total_category_count`, `mtcc`, `modelTotalCategoryCount`:::
  156. include::{docdir}/ml/ml-shared.asciidoc[tag=total-category-count]
  157. `node.address`, `na`, `nodeAddress`:::
  158. The network address of the node.
  159. +
  160. include::{docdir}/ml/ml-shared.asciidoc[tag=node-jobs]
  161. `node.ephemeral_id`, `ne`, `nodeEphemeralId`:::
  162. The ephemeral ID of the node.
  163. +
  164. include::{docdir}/ml/ml-shared.asciidoc[tag=node-jobs]
  165. `node.id`, `ni`, `nodeId`:::
  166. The unique identifier of the node.
  167. +
  168. include::{docdir}/ml/ml-shared.asciidoc[tag=node-jobs]
  169. `node.name`, `nn`, `nodeName`:::
  170. The node name.
  171. +
  172. include::{docdir}/ml/ml-shared.asciidoc[tag=node-jobs]
  173. `opened_time`, `ot`:::
  174. include::{docdir}/ml/ml-shared.asciidoc[tag=open-time]
  175. `state`, `s`:::
  176. (Default)
  177. include::{docdir}/ml/ml-shared.asciidoc[tag=state-anomaly-job]
  178. include::{docdir}/rest-api/common-parms.asciidoc[tag=help]
  179. include::{docdir}/rest-api/common-parms.asciidoc[tag=cat-s]
  180. include::{docdir}/rest-api/common-parms.asciidoc[tag=time]
  181. include::{docdir}/rest-api/common-parms.asciidoc[tag=cat-v]
  182. [[cat-anomaly-detectors-example]]
  183. ==== {api-examples-title}
  184. [source,console]
  185. --------------------------------------------------
  186. GET _cat/ml/anomaly_detectors?h=id,s,dpr,mb&v
  187. --------------------------------------------------
  188. // TEST[skip:kibana sample data]
  189. [source,console-result]
  190. ----
  191. id s dpr mb
  192. high_sum_total_sales closed 14022 1.5mb
  193. low_request_rate closed 1216 40.5kb
  194. response_code_rates closed 28146 132.7kb
  195. url_scanning closed 28146 501.6kb
  196. ----
  197. // TESTRESPONSE[skip:kibana sample data]