Add 'clear' method to SimpleMeterRegistry to support testing
See original GitHub issueThere is no implementation of MeterRegistry
suitable for intergration/e2e tests.
The SimpleMeterRegistry
is almost OK, but it lacks of one major functionality.
Its Meter
s cannot be reset and again filled with metrics.
The close()
method makes the SimpleMeterRegistry
useless when invoked.
Because the SimpleMeterRegistry
is not reusable I need to start Spring Boot application every test method which is a simple waste of time.
Issue Analytics
- State:
- Created 5 years ago
- Comments:9 (7 by maintainers)
Top Results From Across the Web
In Spring Boot, how to reset the metrics ... - Stack Overflow
If you are using a SimpleMeterRegistry you could do: registry.getMeters(). ... You can use clear() method ... In case that doesn't help:.
Read more >Quick Guide to Micrometer - Baeldung
CompositeMeterRegistry allows multiple registries to be added. It provides a solution to publish application metrics to various supported ...
Read more >Working with Metrics - Exploring Pravega
startWithoutExporting() : Initializes SimpleMeterRegistry that holds the latest value of each Meter in memory and does not export the data anywhere, typically ...
Read more >io.micrometer.core.instrument.simple.SimpleMeterRegistry ...
Micrometer.configure(...) SimpleMeterRegistry r = new SimpleMeterRegistry(simple(conf), Clock.SYSTEM); registries.add(r);. origin: reactor/reactor-core ...
Read more >Index (micrometer-core 1.1.2 API) - javadoc.io
Add accept header. acceptJson() - Method in class io.micrometer.core.ipc.http.HttpSender.Request.Builder. Add header to accept application/json ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@kurtharriger @checketts I created #1069 for this.
@kurtharriger You are correct that
clear()
doesn’t yet exist. The referenced tickets like #479 solved removing a single meter, clear would just be a convenience method around fetching all meters and removing each one.