# Querying System Metrics

Abstract

SummaryAn overview of the available system metrics and how to retrieve them.

Alooma exposes a set of metrics which you can use to track the health and status of your data-pipeline.

• Call get_metrics_by_names(metric_names, minutes) to get system metrics.

• metric_names is either one or a list of supported metric names, and minutes is minutes back from the current time. For every metric you can specify the number of minutes over which to pull the information. For example, you could pull the average event size in bytes (EVENT_SIZE_AVG) over the last 60 minutes, via something like: get_metrics_by_names(EVEN_SIZE_AVG, 60)

• The various metric names are:

Copy
'EVENT_SIZE_AVG' - Average event size, in bytes
'EVENT_PROCESSING_RATE' - Number of events processed per minute

# Point-in-time Metrics
'EVENTS_IN_PIPELINE' - This is the incoming queue
'EVENTS_IN_TRANSIT' - This is, in effect, the restream queue

# Events Processed
'INCOMING_EVENTS' - Number of events received
'RESTREAMED_EVENTS' - Number of events restreamed

# Events Sent To Restream
'UNMAPPED_EVENTS'
'IGNORED_EVENTS'
'ERROR_EVENTS'

# Latencies Returned in Seconds
'LATENCY_AVG'
'LATENCY_PERCENTILE_50'
'LATENCY_PERCENTILE_95'
'LATENCY_MAX' - Usually the most important/useful of the latency metrics

• The return value is a list, with the same size and order as: metric_names, where each element is a dictionary with datapoints and target keys. target is the name of the metric, and datapoints is an array of 2-tuples of (value, timestamp).