Skip to content

Commit 1cddedb

Browse files
committed
In essential-metrics.md, added sections for Table Statistics and Disaster Recovery.
Regenerated metrics.yaml using v25.3.0-beta.1.
1 parent e64295e commit 1cddedb

File tree

3 files changed

+119
-13
lines changed

3 files changed

+119
-13
lines changed

src/current/_data/v25.3/metrics/metrics.yaml

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12424,6 +12424,22 @@ layers:
1242412424
unit: BYTES
1242512425
aggregation: AVG
1242612426
derivative: NONE
12427+
- name: kv.rangefeed.mux_stream_send.latency
12428+
exported_name: kv_rangefeed_mux_stream_send_latency
12429+
description: Latency of sending RangeFeed events to the client
12430+
y_axis_label: Latency
12431+
type: HISTOGRAM
12432+
unit: NANOSECONDS
12433+
aggregation: AVG
12434+
derivative: NONE
12435+
- name: kv.rangefeed.mux_stream_send.slow_events
12436+
exported_name: kv_rangefeed_mux_stream_send_slow_events
12437+
description: Number of RangeFeed events that took longer than 10s to send to the client
12438+
y_axis_label: Events
12439+
type: COUNTER
12440+
unit: COUNT
12441+
aggregation: AVG
12442+
derivative: NON_NEGATIVE_DERIVATIVE
1242712443
- name: kv.rangefeed.output_loop_unbuffered_registration_nanos
1242812444
exported_name: kv_rangefeed_output_loop_unbuffered_registration_nanos
1242912445
description: Duration of the Rangefeed O(range) output loop goroutine. This is only applicable for unbuffered registrations since buffered registrations spawns long-living goroutines.
@@ -15137,6 +15153,14 @@ layers:
1513715153
unit: COUNT
1513815154
aggregation: AVG
1513915155
derivative: NONE
15156+
- name: replicas.cpunanospersecond
15157+
exported_name: replicas_cpunanospersecond
15158+
description: Nanoseconds of CPU time in Replica request processing including evaluation but not replication
15159+
y_axis_label: Nanoseconds
15160+
type: COUNTER
15161+
unit: NANOSECONDS
15162+
aggregation: AVG
15163+
derivative: NON_NEGATIVE_DERIVATIVE
1514015164
- name: replicas.leaders
1514115165
exported_name: replicas_leaders
1514215166
description: Number of raft leaders

src/current/_includes/v25.3/essential-metrics.md

Lines changed: 94 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33

44
These essential CockroachDB metrics let you monitor your CockroachDB {{ site.data.products.core }} cluster. Use them to build custom dashboards with the following tools:
55

6-
{% comment %} Assign variables specific to deployment {% endcomment %}
6+
{% comment %} STEP 1. Assign variables specific to deployment {% endcomment %}
77
{% if include.deployment == 'self-hosted' %}
88
{% assign metrics_datadog = site.data[version].metrics.datadog-cockroachdb %}
99
{% assign datadog_link = "https://docs.datadoghq.com/integrations/cockroachdb/?tab=host#metrics" %}
@@ -17,7 +17,7 @@ These essential CockroachDB metrics let you monitor your CockroachDB {{ site.dat
1717
{% assign metrics_datadog = site.data[version].metrics.datadog-crdb-dedicated %}
1818
{% assign datadog_link = "https://docs.datadoghq.com/integrations/cockroach-cloud/#metrics" %}
1919
{% assign datadog_prefix = "crdb_dedicated" %}
20-
{% comment %} Removed NETWORKING category {% endcomment %}
20+
{% comment %} Removed NETWORKING category for advanced deployment {% endcomment %}
2121
{% assign category_order = "HARDWARE,STORAGE,OVERLOAD,DISTRIBUTED,REPLICATION,SQL,CHANGEFEEDS,TTL,UNSET," %}
2222

2323
- [Datadog integration]({% link cockroachcloud/tools-page.md %}#monitor-cockroachdb-cloud-with-datadog) - The [**Datadog Integration Metric Name**]({{ datadog_link }}) column lists the corresponding Datadog metric which requires the `{{ datadog_prefix }}` prefix.
@@ -29,16 +29,16 @@ The **Usage** column explains why each metric is important to visualize and how
2929

3030
{% assign layers = site.data[version].metrics.metrics.layers %}
3131

32-
{% comment %} Create layer name array {% endcomment %}
32+
{% comment %} STEP 2. Create array of layer names {% endcomment %}
3333
{% assign layer_names_string = "" %}
3434
{% for layer in layers %}
3535
{% assign layer_names_string = layer_names_string | append: layer.name | append: "," %}
3636
{% endfor %}
37-
{% comment %} Order layers {% endcomment %}
37+
3838
{% comment %}DEBUG: layer_names_string = {{ layer_names_string }}{% endcomment %}
3939
{% assign layer_names_array = layer_names_string | split: "," %}
4040

41-
{% comment %} Create string of unique category names {% endcomment %}
41+
{% comment %} STEP 3. Create array of unique category names {% endcomment %}
4242
{% assign category_names_string = "" %}
4343
{% for layer_name in layer_names_array %}
4444
{% assign layer = layers | where_exp: "l", "l.name == layer_name" %}
@@ -60,12 +60,11 @@ The **Usage** column explains why each metric is important to visualize and how
6060
{% comment %}DEBUG: category_names_string_ordered = {{ category_names_string_ordered }}{% endcomment %}
6161
{% assign category_names_array = category_names_string_ordered | split: "," %}
6262

63-
{% comment %} Create sections for each unique category. For example, both APPLICATION and STORAGE layers have a SQL category. {% endcomment %}
63+
{% comment %} STEP 4. Create sections for each unique category. For example, both APPLICATION and STORAGE layers have a SQL category, however only one SQL category will be created. {% endcomment %}
6464
{% for category_name in category_names_array %}
6565
{% if category_name != "" %}
6666

67-
{% comment %} Create sections for each unique category {% endcomment %}
68-
{% comment %} Loop 1 to count essential metrics {% endcomment %}
67+
{% comment %} STEP 4a. Loop 1 to count essential metrics {% endcomment %}
6968
{% assign essential_metrics_total = 0 %}
7069
{% for layer_name in layer_names_array %}
7170
@@ -79,9 +78,10 @@ The **Usage** column explains why each metric is important to visualize and how
7978

8079
{% endfor %}{% comment %}for layer in layer_names_array{% endcomment %}
8180

82-
{% comment %} Only create a section for a category if essential metrics exist. For example, the UNSET category does not have any essential metrics.{% endcomment %}
81+
{% comment %} STEP 4b. Only create a section for a category if essential metrics exist. For example, the UNSET category does not have any essential metrics.{% endcomment %}
8382
{% if essential_metrics_total > 0 %}
8483

84+
{% comment %} Transform category_name to user-facing name. {% endcomment %}
8585
{% if category_name == "HARDWARE" %}{% assign category_display_name = "Platform" %}
8686
{% elsif category_name == "STORAGE" %}{% assign category_display_name = "Storage" %}
8787
{% elsif category_name == "OVERLOAD" %}{% assign category_display_name = "Health" %}
@@ -107,15 +107,18 @@ The **Usage** column explains why each metric is important to visualize and how
107107
</thead>
108108
<tbody>
109109

110-
{% comment %} Loop 2 to print essential metrics for category{% endcomment %}
110+
{% comment %} STEP 4c. Loop 2 to create essential metric rows for category{% endcomment %}
111111
{% for layer_name in layer_names_array %}
112112
113-
{% assign layer = layers | where_exp: "l", "l.name == layer_name" %}
113+
{% assign layer = layers | where_exp: "l", "l.name == layer_name" %}
114114
{% assign category = layer[0].categories | where_exp: "c", "c.name == category_name" %}
115115
{% assign essential_metrics = category[0].metrics | where: "essential", true %}
116116
{% comment %}DEBUG: 1 {{ layer_name }} 2 {{ layer[0].name }} 3 {{ category[0].name }}{% endcomment %}
117117

118118
{% for metric in essential_metrics %}
119+
{% comment %} STEP 4d. Exclude SQL metrics that will be placed in special categories {% endcomment %}
120+
{% unless category_name == SQL %}
121+
{% unless metric.name contains "backup" or metric.name contains "BACKUP" or metric.name contains "create_stats" %}
119122

120123
{% comment %} Transforms to match datadog_id {% endcomment %}
121124
{% assign input_metric = metric.name %}
@@ -154,16 +157,95 @@ The **Usage** column explains why each metric is important to visualize and how
154157
<td>{{ metric.how_to_use }}</td>
155158
</tr>
156159

160+
{% endunless %}{% comment %}unless metric.name contains "backup" or metric.name contains "BACKUP" or metric.name contains "create_stats"{% endcomment %}
161+
{% endunless %}{% comment %}unless category_name == SQL{% endcomment %}
157162
{% endfor %}{% comment %}for metric in essential_metrics{% endcomment %}
158163
{% endfor %}{% comment %}for layer in layer_names_array{% endcomment %}
159164

160165
</tbody>
161166
</table>
167+
162168
{% endif %}{% comment %}essential_metrics_total > 0{% endcomment %}
169+
170+
{% comment %} STEP 4e. Create SQL special categories {% endcomment %}
171+
{% if category_name == "SQL" %}
172+
{% assign layer = layers | where_exp: "l", "l.name == 'APPLICATION'" %}
173+
{% assign category = layer[0].categories | where_exp: "c", "c.name == category_name" %}
174+
{% assign essential_metrics = category[0].metrics | where: "essential", true %}
175+
176+
## Table Statistics
177+
178+
<table markdown="1">
179+
<thead>
180+
<tr>
181+
<th>CockroachDB Metric Name</th>
182+
<th>[Datadog Integration Metric Name]({{ datadog_link }})<br>(add `{{ datadog_prefix }}.` prefix)</th>
183+
<th>Description</th>
184+
<th>Usage</th>
185+
</tr>
186+
</thead>
187+
<tbody>
188+
189+
{% for metric in essential_metrics %}
190+
{% if metric.name contains "create_stats" %}
191+
{% assign metric_link = metric.name | replace: "_", "-" | replace: ".", "-" %}
192+
193+
<tr>
194+
<td><div id="{{ metric_link }}" class="anchored"><code>{{ metric.name }}</code></div>
195+
<br>{% if metric.labeled_name %}<code>metrics</code> endpoint:<br><code>{{ metric.labeled_name }}</code>{% endif %}
196+
</td>
197+
<td><code>{{ metric.name }}</code>
198+
</td>
199+
<td>{{ metric.description }}</td>
200+
<td>{{ metric.how_to_use }}</td>
201+
</tr>
202+
203+
{% endif %}
204+
{% endfor %}
205+
206+
</tbody>
207+
</table>
208+
209+
## Disaster Recovery
210+
211+
<table markdown="1">
212+
<thead>
213+
<tr>
214+
<th>CockroachDB Metric Name</th>
215+
<th>[Datadog Integration Metric Name]({{ datadog_link }})<br>(add `{{ datadog_prefix }}.` prefix)</th>
216+
<th>Description</th>
217+
<th>Usage</th>
218+
</tr>
219+
</thead>
220+
<tbody>
221+
222+
{% for metric in essential_metrics %}
223+
{% if metric.name contains "backup" or metric.name contains "BACKUP" %}
224+
225+
{% assign metric_link = metric.name | replace: "_", "-" | replace: ".", "-" %}
226+
227+
<tr>
228+
<td><div id="{{ metric_link }}" class="anchored"><code>{{ metric.name }}</code></div>
229+
<br>{% if metric.labeled_name %}<code>metrics</code> endpoint:<br><code>{{ metric.labeled_name }}</code>{% endif %}
230+
</td>
231+
<td><code>{{ metric.name }}</code>
232+
</td>
233+
<td>{{ metric.description }}</td>
234+
<td>{{ metric.how_to_use }}</td>
235+
</tr>
236+
237+
{% endif %}
238+
{% endfor %}
239+
240+
</tbody>
241+
</table>
242+
243+
{% endif %}{% comment %}if category_name == "SQL"{% endcomment %}
244+
163245
{% endif %}{% comment %}if category_name != ""{% endcomment %}
164246
{% endfor %}{% comment %}for category_name in category_names_array{% endcomment %}
165247

166-
{% comment %} Add category for metrics that are not in metrics.yaml{% endcomment %}
248+
{% comment %} STEP 5. Add category for metrics that are not in metrics.yaml{% endcomment %}
167249
{% if include.deployment == 'self-hosted' %}
168250
{% assign essential_metrics = site.data[version].metrics.available-metrics-not-in-metrics-list | where: "essential", true %}
169251
## Expiration of license and certificates

src/current/v25.3/essential-metrics-self-hosted.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,4 @@ summary: Learn about the recommended essential metrics for monitoring your Cockr
44
toc: true
55
---
66

7-
{% include {{ page.version.version }}/essential-metrics.md deployment='self-hosted' %}
7+
{% include {{ page.version.version }}/essential-metrics.md deployment='self-hosted' %}

0 commit comments

Comments
 (0)