Skip to content

Commit 392f40e

Browse files
committed
fixed from code review
Signed-off-by: Attila Mészáros <a_meszaros@apple.com>
1 parent 05de31a commit 392f40e

File tree

2 files changed

+5
-11
lines changed

2 files changed

+5
-11
lines changed

docs/content/en/docs/documentation/observability.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -127,8 +127,8 @@ All meters use `controller.name` as their primary tag. Counters optionally carry
127127

128128
\* `namespace` tag is only included when `withNamespaceAsTag()` is enabled.
129129

130-
The execution timer uses explicit SLO boundaries (10ms, 50ms, 100ms, 250ms, 500ms, 1s, 2s, 5s, 10s, 30s) to ensure
131-
compatibility with `histogram_quantile()` queries in Prometheus. This is important when using the OTLP registry, where
130+
The execution timer uses explicit boundaries (10ms, 50ms, 100ms, 250ms, 500ms, 1s, 2s, 5s, 10s, 30s) to ensure
131+
compatibility with `histogram_quantile()` queries in Prometheus. This is important when using the OpenTelemetry Protocol (OTLP) registry, where
132132
`publishPercentileHistogram()` would otherwise produce Base2 Exponential Histograms that are incompatible with classic
133133
`_bucket` queries.
134134

micrometer-support/src/main/java/io/javaoperatorsdk/operator/monitoring/micrometer/MicrometerMetricsV2.java

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,6 @@
2222
import java.util.function.Consumer;
2323
import java.util.function.Function;
2424

25-
import org.jspecify.annotations.NonNull;
26-
2725
import io.fabric8.kubernetes.api.model.HasMetadata;
2826
import io.javaoperatorsdk.operator.OperatorException;
2927
import io.javaoperatorsdk.operator.api.monitoring.Metrics;
@@ -179,11 +177,7 @@ public void eventReceived(Event event, Map<String, Object> metadata) {
179177
Tag.of(ACTION, resourceEvent.getAction().toString()));
180178
} else {
181179
incrementCounter(
182-
EVENTS_RECEIVED,
183-
null,
184-
metadata,
185-
Tag.of(EVENT, event.getClass().getSimpleName()),
186-
Tag.of(ACTION, UNKNOWN_ACTION));
180+
EVENTS_RECEIVED, null, metadata, Tag.of(EVENT, event.getClass().getSimpleName()));
187181
}
188182
}
189183

@@ -267,11 +261,11 @@ private void incrementCounter(
267261
registry.counter(counterName, tags).increment();
268262
}
269263

270-
private static @NonNull String reconciliationExecutionGaugeRefKey(String controllerName) {
264+
private static String reconciliationExecutionGaugeRefKey(String controllerName) {
271265
return RECONCILIATIONS_EXECUTIONS_GAUGE + "." + controllerName;
272266
}
273267

274-
private static @NonNull String controllerQueueSizeGaugeRefKey(String controllerName) {
268+
private static String controllerQueueSizeGaugeRefKey(String controllerName) {
275269
return RECONCILIATIONS_QUEUE_SIZE_GAUGE + "." + controllerName;
276270
}
277271

0 commit comments

Comments
 (0)