1.6.x is an LTS release line - see the support page for more information on LTS vs non-LTS releases. This release contains changes from the 1.6.0 milestone.
Thank you to all the people who contributed to this release.
Compatibility impacting
-
Timer.Sample
'stags
methods and thestop
method that takes aTimer.Builder
have been removed. Instead, tags should be specified on theTimer
passed to the remainingstop
method. This makes for consistency - tags are always configured on the Timer.Example before/after Timer.Sample code
Old code Supported code Timer.Sample sample = Timer.start(meterRegistry); // ... do some stuff sample.tags("flag", flag); sample.tags(Tags.of("other", "tag")); sample.stop(meterRegistry, Timer.builder("sample.time"));
Timer.Sample sample = Timer.start(meterRegistry); // ... do some stuff sample.stop(Timer.builder("sample.time") .tag("flag", flag) .tags(Tags.of("other", "tag")) .register(meterRegistry));
-
HibernateMetrics
requires Hibernate 5.3 or later now. -
Kafka
metrics - #2256 The tag for client id on Kafka metrics has been changed fromclient-id
toclient.id
to match the previous version of Kafka metrics fromKafkaConsumerMetrics
and to follow our canonical format. Likewisekafka-version
has been updated tokafka.version
. AMeterFilter
can be applied to undo the tag name change or to apply this change to 1.5.x versions of Micrometer. For example:
Users who wantclient.id
in 1.5.x should configureMeterFilter.renameTag("kafka", "client-id", "client.id")
Users who wantclient-id
in 1.6.x should configure the opposite filter:MeterFilter.renameTag("kafka", "client.id", "client-id")
.
Registry-specific
[ElasticMeterRegistry]
#2288 Default index name prefix has been changed frommetrics
tomicrometer-metrics
to avoid a conflict with a built-in index template for an xpack feature in Elasticsearch 7.9[GraphiteMeterRegistry]
#2083 Graphite tags should work out of the box now but requires themetrics-graphite
dependency version 4.1.8 or later[GraphiteMeterRegistry]
#2164 In order to retain the final publish on close behavior, users should be using at least version 4.1.8 of themetrics-core
dependency.[WavefrontMeterRegistry]
#2175wavefront-sdk-java
2.4 or later is required now.
New Meter Registries
- HealthMeterRegistry for SLO-based health indicators. See #2055
New metrics
- #1875 Metrics for OkHttp ConnectionPool
- #1712 CommonsObjectPool2Metrics
- #2097 Expose per-region statistics for Hibernate L2 cache
- #2248 Tomcat connection metrics
- #2199 Add counters for QueryPlanCacheHit and QueryPlanCacheMiss in HibernateMetrics
Enhancements
- #1861 Support Shenandoah GC in
JvmGcMetrics
- #2305 Support ZGC in
JvmGcMetrics
- Note: the time provided by the
jvm.gc.pause
Timer is not accurate for ZGC (it includes the concurrent time) see #2372
- Note: the time provided by the
- #2185 Add option to disable illegal access in ExecutorServiceMetrics
- #2068 Add onMeterRegistrationFailed listener configuration to MeterRegistry
Registry-specific changes
CloudWatch
- #2088 Support of high resolution metrics for CloudWatch
Elasticsearch
- #2255 Default index pattern changed for compatibility with Elasticsearch 7.9 xpack metrics index template
Wavefront
- #2175 Allow step intervals at finer than whole second granularity for Wavefront