@intentius/chant-lexicon-prometheus 0.124.46 → 0.124.48

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -8,7 +8,8 @@
8
8
  * Grafana's GRAF118 runs `collectorMetricIssues` over panel queries; the
9
9
  * prometheus lexicon runs it over rule files. Names follow the otel lexicon's
10
10
  * `metric-names.ts`, with each config's `prometheus` and
11
- * `prometheusremotewrite` exporters' `namespace` and `add_metric_suffixes`.
11
+ * `prometheusremotewrite` exporters' `namespace` and `translation_strategy`
12
+ * (and `add_metric_suffixes` for `prometheusremotewrite`).
12
13
  * A component under a renamed type (`span_metrics`, `service_graph`,
13
14
  * `signal_to_metrics`) is read as the built-in it names, through the otel
14
15
  * lexicon's `canonicalTypeOf`.
@@ -1 +1 @@
1
- {"version":3,"file":"collector-metrics.d.ts","sourceRoot":"","sources":["../src/collector-metrics.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;GAoBG;AAEH,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,kCAAkC,CAAC;AAezE,OAAO,EAAmB,KAAK,eAAe,EAAE,MAAM,qCAAqC,CAAC;AAM5F,kEAAkE;AAClE,MAAM,WAAW,aAAa;IAC5B,6DAA6D;IAC7D,SAAS,EAAE,MAAM,CAAC;IAClB,sGAAsG;IACtG,MAAM,CAAC,EAAE,GAAG,CAAC,MAAM,CAAC,CAAC;CACtB;AAED,kDAAkD;AAClD,MAAM,WAAW,gBAAgB;IAC/B,yEAAyE;IACzE,UAAU,EAAE,MAAM,EAAE,CAAC;IACrB,+FAA+F;IAC/F,OAAO,EAAE,GAAG,CAAC,MAAM,EAAE,aAAa,EAAE,CAAC,CAAC;CACvC;AA+BD,oGAAoG;AACpG,wBAAgB,qBAAqB,CAAC,GAAG,EAAE,gBAAgB,GAAG,eAAe,EAAE,CAK9E;AAED,6EAA6E;AAC7E,wBAAgB,gBAAgB,CAAC,OAAO,EAAE,eAAe,EAA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,OAAO,EAAE,MAAM,CAAC;CACjB;AAED;;;;;;;;GAQG;AACH,wBAAgB,qBAAqB,CAAC,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,gBAAgB,GAAG,oBAAoB,EAAE,CA8BrG"}
@@ -8,7 +8,8 @@
8
8
  * Grafana's GRAF118 runs `collectorMetricIssues` over panel queries; the
9
9
  * prometheus lexicon runs it over rule files. Names follow the otel lexicon's
10
10
  * `metric-names.ts`, with each config's `prometheus` and
11
- * `prometheusremotewrite` exporters' `namespace` and `add_metric_suffixes`.
11
+ * `prometheusremotewrite` exporters' `namespace` and `translation_strategy`
12
+ * (and `add_metric_suffixes` for `prometheusremotewrite`).
12
13
  * A component under a renamed type (`span_metrics`, `service_graph`,
13
14
  * `signal_to_metrics`) is read as the built-in it names, through the otel
14
15
  * lexicon's `canonicalTypeOf`.
@@ -70,11 +71,24 @@ export function collectorMetrics(configs) {
70
71
  for (const config of configs) {
71
72
  const exporters = Object.entries(asObj(config.exporters)).filter(([id]) => typeOf("exporter", id) === "prometheus" || typeOf("exporter", id) === "prometheusremotewrite");
72
73
  const namings = exporters.length > 0
73
- ? exporters.map(([, c]) => {
74
+ ? exporters.map(([id, c]) => {
74
75
  const e = asObj(c);
76
+ // The `prometheus` exporter ignores the deprecated `add_metric_suffixes`
77
+ // at the pinned release (#3361); `prometheusremotewrite` still reads it
78
+ // when no `translation_strategy` is set.
79
+ const readsSuffixFlag = typeOf("exporter", id) === "prometheusremotewrite";
80
+ const constant = asObj(e.resource_constant_labels);
75
81
  return {
76
- naming: { ...(typeof e.namespace === "string" ? { namespace: e.namespace } : {}), ...(e.add_metric_suffixes === false ? { add_metric_suffixes: false } : {}) },
77
- openLabels: asObj(e.resource_to_telemetry_conversion).enabled === true,
82
+ naming: {
83
+ ...(typeof e.namespace === "string" ? { namespace: e.namespace } : {}),
84
+ ...(typeof e.translation_strategy === "string" ? { translation_strategy: e.translation_strategy } : {}),
85
+ ...(readsSuffixFlag && e.add_metric_suffixes === false ? { add_metric_suffixes: false } : {}),
86
+ },
87
+ // Resource attributes become labels through the deprecated
88
+ // `resource_to_telemetry_conversion` or its replacement.
89
+ openLabels: asObj(e.resource_to_telemetry_conversion).enabled === true ||
90
+ constant.enabled === true ||
91
+ (Array.isArray(constant.included) && constant.included.length > 0),
78
92
  };
79
93
  })
80
94
  : [{ naming: {}, openLabels: false }];
@@ -85,7 +99,7 @@ export function collectorMetrics(configs) {
85
99
  namespaces.add(prefix(SERVICEGRAPH_NAMESPACE));
86
100
  const add = (connector, m, extra = []) => {
87
101
  const labels = openLabels ? undefined : new Set([...m.dimensions.map(prometheusLabel), ...extra.map(prometheusLabel), ...ADDED_LABELS]);
88
- // A classic histogram is served as three series whatever add_metric_suffixes says.
102
+ // A classic histogram is served as three series whatever the translation strategy.
89
103
  const series = m.type === "histogram"
90
104
  ? [
91
105
  [`${m.prometheus}_bucket`, labels ? new Set([...labels, "le"]) : undefined],
@@ -165,7 +165,7 @@ export const compositeCatalog = [
165
165
  "name": "exporter",
166
166
  "type": "OTelComponent<\"exporter\", \"prometheus\", PrometheusExporterConfig> | PrometheusNaming",
167
167
  "required": false,
168
- "description": "The `prometheus` exporter that serves them, when its `namespace` or `add_metric_suffixes` changes the names."
168
+ "description": "The `prometheus` exporter that serves them, when its `namespace` or `translation_strategy` changes the names."
169
169
  },
170
170
  {
171
171
  "name": "errorRatio",
@@ -46,7 +46,7 @@ export interface RedLatencyAlert extends RedAlertOptions {
46
46
  export interface RedAlertsProps {
47
47
  /** The `spanmetrics` connector the metrics come from (the otel lexicon's `RedMetrics` has it as `spanMetrics`), or the names `spanMetricsNames()` returned for it. */
48
48
  spanMetrics: OTelComponent<"connector", "spanmetrics", SpanMetricsConnectorConfig> | SpanMetricsNames;
49
- /** The `prometheus` exporter that serves them, when its `namespace` or `add_metric_suffixes` changes the names. */
49
+ /** The `prometheus` exporter that serves them, when its `namespace` or `translation_strategy` changes the names. */
50
50
  exporter?: OTelComponent<"exporter", "prometheus", PrometheusExporterConfig> | PrometheusNaming;
51
51
  /** Error ratio per service (default: on, above 0.05). `false` leaves it out. */
52
52
  errorRatio?: boolean | RedErrorRatioAlert;
@@ -1 +1 @@
1
- {"version":3,"file":"red-alerts.d.ts","sourceRoot":"","sources":["../../src/composites/red-alerts.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,EAAa,KAAK,iBAAiB,EAAE,MAAM,4BAA4B,CAAC;AAC/E,OAAO,EAIL,KAAK,gBAAgB,EACrB,KAAK,eAAe,EACpB,KAAK,gBAAgB,EACtB,MAAM,4CAA4C,CAAC;AACpD,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,sCAAsC,CAAC;AAC1E,OAAO,KAAK,EAAE,0BAA0B,EAAE,MAAM,qDAAqD,CAAC;AACtG,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,oDAAoD,CAAC;AACnG,OAAO,EAAa,KAAK,YAAY,EAAE,KAAK,eAAe,EAAE,MAAM,UAAU,CAAC;AAC9E,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,UAAU,CAAC;AAGzC,mCAAmC;AACnC,MAAM,WAAW,eAAe;IAC9B,wDAAwD;IACxD,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,8EAA8E;IAC9E,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,gCAAgC;IAChC,MAAM,CAAC,EAAE,QAAQ,CAAC;IAClB,yDAAyD;IACzD,WAAW,CAAC,EAAE,QAAQ,CAAC;CACxB;AAED,MAAM,WAAW,kBAAmB,SAAQ,eAAe;IACzD,wGAAwG;IACxG,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,WAAW,eAAgB,SAAQ,eAAe;IACtD,qDAAqD;IACrD,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,yGAAyG;IACzG,gBAAgB,CAAC,EAAE,MAAM,CAAC;CAC3B;AAED,MAAM,WAAW,cAAc;IAC7B,sKAAsK;IACtK,WAAW,E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1C,8HAA8H;IAC9H,OAAO,CAAC,EAAE,OAAO,GAAG,eAAe,CAAC;IACpC,0FAA0F;IAC1F,SAAS,CAAC,EAAE,eAAe,EAAE,CAAC;IAC9B,mDAAmD;IACnD,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,wHAAwH;IACxH,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,4IAA4I;IAC5I,OAAO,CAAC,EAAE,MAAM,EAAE,CAAC;IACnB,6CAA6C;IAC7C,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,+CAA+C;IAC/C,MAAM,CAAC,EAAE,QAAQ,CAAC;IAClB,sFAAsF;IACtF,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB;AAED,MAAM,MAAM,gBAAgB,GAAG;IAC7B,0BAA0B;IAC1B,KAAK,EAAE,eAAe,CAAC;CACxB,CAAC;AAEF,iEAAiE;AACjE,MAAM,MAAM,iBAAiB,GAAG,iBAAiB,CAAC,gBAAgB,CAAC,GAAG,gBAAgB,CAAC;AAKvF,0CAA0C;AAC1C,eAAO,MAAM,eAAe;;;EAAwF,CAAC;AAsBrH,yFAAyF;AACzF,wBAAgB,aAAa,CAAC,KAAK,EAAE,cAAc,GAAG,YAAY,EAAE,CAqEnE;AAED;;;;;;;;;;;GAWG;AACH,eAAO,MAAM,SAAS,kFAYP,CAAC"}
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "algorithm": "sha256",
3
3
  "artifacts": {
4
- "manifest.json": "5006c8f8ada2f3ef0ce42cf0f6ea0fcdea7cb5e86d8102a57c05604746c9bc56",
4
+ "manifest.json": "1d662c2a0f7d9035e55c662dee30ebce6d3ec00e3028b151bd57a1b8b5d8c76b",
5
5
  "meta.json": "a06b8059e2de2ca6c8131bfbbfe7e143e818f2d2d497d3f45a9bc5c63af6aeeb",
6
6
  "types/index.d.ts": "150d72287453a24a40cdeffb8cf3e9dc6e77ab58b342b48d01902dc58fb5f85d",
7
7
  "rules/literal-credential.ts": "df0dc02b93f2da87d9b03ceca906206b40b3b7600b24cb733f6388d81f92aecb",
@@ -46,5 +46,5 @@
46
46
  "skills/chant-prometheus-alertmanager.md": "4c4a22bea6147653d09d7d3f55f81c4927963d4e2f50b2e430fbb9023e99570b",
47
47
  "skills/chant-prometheus-kubernetes.md": "cca016857891f4cabf1feb6f9db83c220a2e6ece200cd89e635851079f8070a8"
48
48
  },
49
- "composite": "606897f9bdb7e0fe4bd4b71420ae36bc377102492c01066d7302b182eeda83c7"
49
+ "composite": "b4b90adcd7af2ea094a198f2f44fd7bb289658590e4d1968a4cf751d86ca3f48"
50
50
  }
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "prometheus",
3
- "version": "0.124.46",
3
+ "version": "0.124.48",
4
4
  "chantVersion": ">=0.1.0",
5
5
  "namespace": "Prometheus",
6
6
  "intrinsics": [],
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@intentius/chant-lexicon-prometheus",
3
- "version": "0.124.46",
3
+ "version": "0.124.48",
4
4
  "description": "Prometheus lexicon for chant — typed recording and alerting rule groups and Alertmanager routing, serialized to a rule file and alertmanager.yml",
5
5
  "license": "Apache-2.0",
6
6
  "homepage": "https://intentius.io/chant",
@@ -74,7 +74,7 @@
74
74
  "build": "../../scripts/tsc7.sh -p tsconfig.build.json --sourceMap false && tsc-alias -p tsconfig.build.json"
75
75
  },
76
76
  "dependencies": {
77
- "@intentius/chant-lexicon-otel": "^0.124.46",
77
+ "@intentius/chant-lexicon-otel": "^0.124.48",
78
78
  "@lezer/highlight": "^1.2.4",
79
79
  "@lezer/lr": "^1.4.10",
80
80
  "@prometheus-io/lezer-promql": "0.315.0",
@@ -88,6 +88,6 @@
88
88
  "typescript": "^5.9.3"
89
89
  },
90
90
  "peerDependencies": {
91
- "@intentius/chant": "^0.124.46"
91
+ "@intentius/chant": "^0.124.48"
92
92
  }
93
93
  }
@@ -8,7 +8,8 @@
8
8
  * Grafana's GRAF118 runs `collectorMetricIssues` over panel queries; the
9
9
  * prometheus lexicon runs it over rule files. Names follow the otel lexicon's
10
10
  * `metric-names.ts`, with each config's `prometheus` and
11
- * `prometheusremotewrite` exporters' `namespace` and `add_metric_suffixes`.
11
+ * `prometheusremotewrite` exporters' `namespace` and `translation_strategy`
12
+ * (and `add_metric_suffixes` for `prometheusremotewrite`).
12
13
  * A component under a renamed type (`span_metrics`, `service_graph`,
13
14
  * `signal_to_metrics`) is read as the built-in it names, through the otel
14
15
  * lexicon's `canonicalTypeOf`.
@@ -104,11 +105,25 @@ export function collectorMetrics(configs: CollectorConfig[]): CollectorMetrics |
104
105
  const exporters = Object.entries(asObj(config.exporters)).filter(([id]) => typeOf("exporter", id) === "prometheus" || typeOf("exporter", id) === "prometheusremotewrite");
105
106
  const namings: Array<{ naming: PrometheusNaming; openLabels: boolean }> =
106
107
  exporters.length > 0
107
- ? exporters.map(([, c]) => {
108
+ ? exporters.map(([id, c]) => {
108
109
  const e = asObj(c);
110
+ // The `prometheus` exporter ignores the deprecated `add_metric_suffixes`
111
+ // at the pinned release (#3361); `prometheusremotewrite` still reads it
112
+ // when no `translation_strategy` is set.
113
+ const readsSuffixFlag = typeOf("exporter", id) === "prometheusremotewrite";
114
+ const constant = asObj(e.resource_constant_labels);
109
115
  return {
110
- naming: { ...(typeof e.namespace === "string" ? { namespace: e.namespace } : {}), ...(e.add_metric_suffixes === false ? { add_metric_suffixes: false } : {}) },
111
- openLabels: asObj(e.resource_to_telemetry_conversion).enabled === true,
116
+ naming: {
117
+ ...(typeof e.namespace === "string" ? { namespace: e.namespace } : {}),
118
+ ...(typeof e.translation_strategy === "string" ? { translation_strategy: e.translation_strategy } : {}),
119
+ ...(readsSuffixFlag && e.add_metric_suffixes === false ? { add_metric_suffixes: false } : {}),
120
+ },
121
+ // Resource attributes become labels through the deprecated
122
+ // `resource_to_telemetry_conversion` or its replacement.
123
+ openLabels:
124
+ asObj(e.resource_to_telemetry_conversion).enabled === true ||
125
+ constant.enabled === true ||
126
+ (Array.isArray(constant.included) && constant.included.length > 0),
112
127
  };
113
128
  })
114
129
  : [{ naming: {}, openLabels: false }];
@@ -121,7 +136,7 @@ export function collectorMetrics(configs: CollectorConfig[]): CollectorMetrics |
121
136
 
122
137
  const add = (connector: string, m: CollectorMetric, extra: string[] = []) => {
123
138
  const labels = openLabels ? undefined : new Set([...m.dimensions.map(prometheusLabel), ...extra.map(prometheusLabel), ...ADDED_LABELS]);
124
- // A classic histogram is served as three series whatever add_metric_suffixes says.
139
+ // A classic histogram is served as three series whatever the translation strategy.
125
140
  const series: Array<[string, Set<string> | undefined]> =
126
141
  m.type === "histogram"
127
142
  ? [
@@ -170,7 +170,7 @@ export const compositeCatalog: CompositeEntry[] = [
170
170
  "name": "exporter",
171
171
  "type": "OTelComponent<\"exporter\", \"prometheus\", PrometheusExporterConfig> | PrometheusNaming",
172
172
  "required": false,
173
- "description": "The `prometheus` exporter that serves them, when its `namespace` or `add_metric_suffixes` changes the names."
173
+ "description": "The `prometheus` exporter that serves them, when its `namespace` or `translation_strategy` changes the names."
174
174
  },
175
175
  {
176
176
  "name": "errorRatio",
@@ -59,7 +59,7 @@ export interface RedLatencyAlert extends RedAlertOptions {
59
59
  export interface RedAlertsProps {
60
60
  /** The `spanmetrics` connector the metrics come from (the otel lexicon's `RedMetrics` has it as `spanMetrics`), or the names `spanMetricsNames()` returned for it. */
61
61
  spanMetrics: OTelComponent<"connector", "spanmetrics", SpanMetricsConnectorConfig> | SpanMetricsNames;
62
- /** The `prometheus` exporter that serves them, when its `namespace` or `add_metric_suffixes` changes the names. */
62
+ /** The `prometheus` exporter that serves them, when its `namespace` or `translation_strategy` changes the names. */
63
63
  exporter?: OTelComponent<"exporter", "prometheus", PrometheusExporterConfig> | PrometheusNaming;
64
64
  /** Error ratio per service (default: on, above 0.05). `false` leaves it out. */
65
65
  errorRatio?: boolean | RedErrorRatioAlert;