You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 646892e
Browse filesBrowse the repository at this point in the historyBrowse files
Let applications suppress noisy metrics before event processing using
case-insensitive names or full regular expressions. Support external
configuration, Android manifest metadata, and Spring Boot properties.
Default Spring Boot applications to excluding Logback and Log4j2 counters
to prevent logging-driven queue overload. Preserve explicit lists, including
empty lists, and allow user callbacks to append, replace, or clear defaults.
Keep plain Java and Android defaults unfiltered.
Reuse the core matcher in a Sentry-local Micrometer MeterFilter to avoid
registration and recording overhead without affecting other registries.
Preserve partial exports for meters with multiple possible output names.
Cover configuration, matching, name conversion, and filtering behavior
with tests. Verify that filtering logging counters prevents queue overflow
and preserves business metrics during a 100,000-log-per-second workload.
Co-Authored-By: Codex <noreply@openai.com>
Copy file name to clipboardExpand all lines: CHANGELOG.md
+21Lines changed: 21 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -5,6 +5,27 @@
5
5
### Features
6
6
7
7
- Add a Micrometer metrics integration with opt-in Spring Boot support ([#6116](https://github.com/getsentry/sentry-java/pull/6116))
8
+
- Add `options.getMetrics().setIgnoredMetrics(...)` to filter metric names before processing, including early Micrometer filtering
9
+
- Configure names or full regular-expression patterns through the Java API, Android manifest, `sentry.properties`, or Spring Boot's `application.properties`. Use `[.]` to match a literal dot in a pattern.
10
+
- **Spring Boot 2, 3, and 4 default:** ignore `logback.events` and `log4j2.events` metrics to avoid logging-driven metric queue overload. An explicit list replaces these defaults; an empty list disables filtering. Outside Spring Boot, no metric names are ignored by default. Actual log messages are unaffected.
11
+
- **AndroidManifest.xml:** add `io.sentry.metrics.ignored-metrics` under `<application>`:
12
+
```xml
13
+
<meta-data
14
+
android:name="io.sentry.metrics.ignored-metrics"
15
+
android:value="noisy[.]metric" />
16
+
```
17
+
- **sentry.properties:** use `metrics.ignored-metrics` (requires external configuration to be enabled with `options.setEnableExternalConfiguration(true)`):
18
+
```properties
19
+
metrics.ignored-metrics=noisy[.]metric
20
+
```
21
+
- **Spring Boot application.properties:** use `sentry.metrics.ignored-metrics`. Include the logging patterns to retain the defaults while adding another exclusion:
0 commit comments