Micrometer: Update Caffeine

Created on 23 Feb 2021  路  3Comments  路  Source: micrometer-metrics/micrometer

Caffeine 3.0.0 has been released recently (https://search.maven.org/artifact/com.github.ben-manes.caffeine/caffeine) with some breaking changes, micrometer supports 2.x (https://github.com/micrometer-metrics/micrometer/commit/766fa07804c819a86c4cb7269e4cd752e8a99eee).

Most helpful comment

I believe the only change that impacts this project is StatsCounter. This can be made backwards compatible by retaining the deprecated recordEviction() method and removing the @Override. It should cross compile.

https://github.com/micrometer-metrics/micrometer/blob/c3e2b086faa87e2e404e6548d82df7615a5e958a/micrometer-core/src/main/java/io/micrometer/core/instrument/binder/cache/CaffeineStatsCounter.java#L147-L150

All 3 comments

I believe the only change that impacts this project is StatsCounter. This can be made backwards compatible by retaining the deprecated recordEviction() method and removing the @Override. It should cross compile.

https://github.com/micrometer-metrics/micrometer/blob/c3e2b086faa87e2e404e6548d82df7615a5e958a/micrometer-core/src/main/java/io/micrometer/core/instrument/binder/cache/CaffeineStatsCounter.java#L147-L150

@ben-manes Thanks! I created https://github.com/micrometer-metrics/micrometer/pull/2476 to try to resolve this.

Fixed in #2478

Was this page helpful?
0 / 5 - 0 ratings