Closed barchetta closed 6 years ago
The issue is that a Histogram
relies on an ExponentiallyDecayingReservoir
where weighted sample data is stored. The weights are computed based on the time an item is added to the histogram. If the test does not add all the items within a second, the weights will differ and the test fails as shown above. This could easily happen on a slow machine or if artificial sleeps are introduced in the test while data is being added (with those added, the test fails every single time).
A potential workaround is to pass the timestamp for registration to ensure all data is registered at the same time, or at least pretend that to be the case. This is possible if histograms provide access to their underlying delegates and if some private access is changed to package private for testing purposes. A PR is on the way.
Helidon Version: 0.10.0-SNAPSHOT
Occasionally in pipeline runs I get failures in some of the Metrics tests. This does not happen often, and a retry usually clears it up. You can see a failed run here: https://app.wercker.com/Helidon/helidon/runs/build/5b9ad0a98c38a200070cd426?step=5b9ad0dbf07af00007d84713
An excerpt