Get datafeed stats
- GET /_ml/datafeeds/{datafeed_id}/_stats
- GET /_ml/datafeeds/_stats
You can get statistics for multiple datafeeds in a single API request by
using a comma-separated list of datafeeds or a wildcard expression. You can
get statistics for all datafeeds by using _all, by specifying * as the
<feed_id>, or by omitting the <feed_id>. If the datafeed is stopped, the
only information you receive is the datafeed_id and the state.
This API returns a maximum of 10,000 datafeeds.
- Cluster privileges:
monitor_ml
Path Parameters
-
datafeed_idId | Idoptional -
Identifier for the datafeed. It can be a datafeed identifier or a wildcard expression. If you do not specify one of these options, the API returns information about all datafeeds.
Leave it out to use
/_ml/datafeeds/_stats.
Query Parameters
-
allow_no_matchboolean Specifies what to do when the request:
- Contains wildcard expressions and there are no datafeeds that match.
- Contains the
_allstring or no identifiers and there are no matches. - Contains wildcard expressions and there are only partial matches.
The default value is
true, which returns an emptydatafeedsarray when there are no matches and the subset of results when there are partial matches. If this parameter isfalse, the request returns a404status code when there are no matches or only partial matches.
Response
-
countnumberrequired -
datafeedsDatafeedStatsrequired -
assignment_explanationstring -
For started datafeeds only, contains messages relating to the selection of a node.
-
datafeed_idstring Idrequired -
A numerical character string that uniquely identifies the datafeed. This identifier can contain lowercase alphanumeric characters (a-z and 0-9), hyphens, and underscores. It must start and end with alphanumeric characters.
-
stateDatafeedStaterequired -
The status of the datafeed, which can be one of the following values:
starting,started,stopping,stopped. -
Values:
startedstoppedstartingstopping -
timing_statsDatafeedTimingStats -
An object that provides statistical information about timing aspect of this datafeed.
-
bucket_countnumberrequired -
The number of buckets processed.
-
exponential_average_search_time_per_hour_msDurationValueUnitFloatMillisrequired -
The exponential average search time per hour, in milliseconds.
-
exponential_average_calculation_contextExponentialAverageCalculationContext -
incremental_metric_value_msDurationValueUnitFloatMillisrequired -
latest_timestampEpochTimeUnitMillis -
previous_exponential_average_msDurationValueUnitFloatMillis -
job_idstring Idrequired -
Identifier for the anomaly detection job.
-
search_countnumberrequired -
The number of searches run by the datafeed.
-
total_search_time_msDurationValueUnitFloatMillisrequired -
The total time the datafeed spent searching, in milliseconds.
-
average_search_time_per_bucket_msDurationValueUnitFloatMillis -
The average search time per bucket, in milliseconds.
-
running_stateDatafeedRunningState -
An object containing the running state for this datafeed. It is only provided if the datafeed is started.
-
real_time_configuredbooleanrequired -
Indicates if the datafeed is "real-time"; meaning that the datafeed has no configured
endtime. -
real_time_runningbooleanrequired -
Indicates whether the datafeed has finished running on the available past data. For datafeeds without a configured
endtime, this means that the datafeed is now running on "real-time" data. -
search_intervalRunningStateSearchInterval -
Provides the latest time interval the datafeed has searched.