Metrics
Pick a metric, slice it by attributes, plot it. What the four chart types show, how to combine metrics, and how to save a query as a dashboard panel.
The Metrics screen turns your numeric time-series — latency, throughput, saturation — into charts you filter, group, and aggregate on the fly.
What the screen does
You pick a metric (e.g. http.server.request.duration), optionally filter and group it by attributes (e.g. service.name, route), pick an aggregation (rate, p99, sum…), and Orbtrace plots it. That's the whole loop.
Layout
- ① Metric pickerA searchable dropdown at the top-left. As you type, it shows matching metric names with their kind (counter / gauge / histogram) and units.
- ② Filter stripAdd attribute filters (e.g.
service.name = checkout-api,route =~ /api/.*). Add as many as you like. AND between filters. - ③ Group-by chipsAttributes to split the series by. Adding
service.nameto group-by draws one line per service. - ④ AggregationA dropdown that depends on the metric's kind. Counters →
rate,increase,sum. Gauges →avg,min,max,last. Histograms →p50,p95,p99,count,sum. - ⑤ ChartA line / area / bar chart. See below.
- ⑥ Legend tableOne row per series. Each row shows the line colour, the group-by values, the current value, min, max, average.
- ⑦ Action buttons"Save as panel", "Create alert from this query", "Open in Replay".
The four chart types
A toggle in the chart's top-right corner switches type. Pick the type that matches what you're asking.
- LineFor rates and gauges over time. Use when you want to see the trend. Multiple series overlay.
- Area (stacked)For decomposing a total — e.g. requests per second per service stacked. Use when the sum is the story.
- BarFor discrete buckets — error counts per minute. Use when buckets are independent (no smoothing).
- HeatmapFor histograms. The X axis is time, Y axis is the histogram's bucket, colour is count. Use to find tail-latency outliers that an average hides.
Aggregations — what each one means
- rate(metric[window])For counters. "How many events per second, averaged over the window."
rate(http.server.requests_total[1m])= requests/sec smoothed over a minute. - increase(metric[window])For counters. Like
ratebut reports the raw count over the window, not per second. - sumSum across series (after group-by). Often
sum(rate(...))to get a fleet-wide rate. - p50 / p95 / p99For histograms only. Returns the percentile within each bucket on the time axis.
- avg / min / maxFor gauges. The within-bucket statistic.
- lastFor gauges. The most recent value in the bucket.
Combining metrics — the formula bar
Below the picker is an optional formula input. Use it to do arithmetic across queries:
A: rate(http.server.requests_total{status=~"5.."}[1m])
B: rate(http.server.requests_total[1m])
formula: A / BThat plots the 5xx error rate as a fraction. Lettered queries (A, B, C…) are listed in the legend and contribute independently if you don't supply a formula.
How to read percentile heatmaps
Hardest chart to read, most useful for incidents. Each row of the heatmap is a latency bucket (e.g. 10–20 ms, 20–50 ms, …). Each column is a time bucket. Cell colour is "how many requests landed in this latency bucket during this time bucket".
A healthy service looks like a thin bright band low on the chart. A service developing a tail-latency problem grows a faint band higher up. The exact moment that band brightens is when your p99 latency went bad — earlier than any percentile line would show. Tail-aware heatmaps are why dashboards include them.
Saving a chart as a dashboard panel
Click Save as panel → a dialog asks which dashboard to add it to (existing or new), the panel title, and the visualisation type. Confirm. The current filter, group-by, and aggregation are captured exactly.
Creating an alert from a query
Click Create alert from this query. You're taken to Alerts → New with the query already filled in. You set the threshold, the for-duration, and the routing. See the alerts page for what each of those means.
Opening in Replay
Click Open in Replay. The current query becomes the "actual outcome" timeline in Time-Travel Replay, where you can ask counterfactuals like "what if we hadn't deployed?". The metric you were looking at is now the variable Replay is asked to predict.
Tips that pay off
- Filter before group-by. Group-by on an unfiltered high-cardinality attribute (like
user_id) will draw a thousand series and slow the page. Filter first, group last. - Use percentile, not average, for latency. Averages hide tails. p99 is the SRE default.
- For "is X slowing down a fleet", stack-area on service.name. Fastest read of "who's growing".
- Save a frequently-asked query as a panel. A dashboard turns "I have to remember the filter" into "I open the same page every morning".
Next: Dashboards.