Get anomaly detection job stats
- GET /_ml/anomaly_detectors/{job_id}/_stats
- GET /_ml/anomaly_detectors/_stats
Required authorization
- Cluster privileges monitor_ml
Path parameters
-
job_idstringoptional -
Identifier for the anomaly detection job. It can be a job identifier, a group name, a comma-separated list of jobs, or a wildcard expression. If you do not specify one of these options, the API returns information for all anomaly detection jobs.
Leave it out to use
/_ml/anomaly_detectors/_stats.
Query parameters
-
allow_no_matchboolean · default: true -
Specifies what to do when the request:
- Contains wildcard expressions and there are no jobs that match.
- Contains the _all string or no identifiers and there are no matches.
- Contains wildcard expressions and there are only partial matches.
If
true, the API returns an emptyjobsarray when there are no matches and the subset of results when there are partial matches. Iffalse, the API returns a404status code when there are no matches or only partial matches.
Response
-
jobsobjectrequired -
assignment_explanationstring -
For open anomaly detection jobs only, contains messages relating to the selection of a node to run the job.
-
data_countsobjectrequired -
An object that describes the quantity of input to the job and any related error counts. The
data_countvalues are cumulative for the lifetime of a job. If a model snapshot is reverted or old results are deleted, the job counts are not reset. -
forecasts_statsobjectrequired -
An object that provides statistical information about forecasts belonging to this job. Some statistics are omitted if no forecasts have been made.
-
model_size_statsobjectrequired -
An object that provides information about the size and contents of the model.
-
staterequired -
The status of the anomaly detection job, which can be one of the following values:
closed,closing,failed,opened,opening.Supported values include:
closing: The job close action is in progress and has not yet completed. A closing job cannot accept further data.closed: The job finished successfully with its model state persisted. The job must be opened before it can accept further data.opened: The job is available to receive and process data.failed: The job did not finish successfully due to an error. This situation can occur due to invalid input data, a fatal error occurring during the analysis, or an external interaction such as the process being killed by the Linux out of memory (OOM) killer. If the job had irrevocably failed, it must be force closed and then deleted. If the datafeed can be corrected, the job can be closed and then re-opened.opening: The job open action is in progress and has not yet completed.
-
Values:
closingclosedopenedfailedopening