nizhikov commented on a change in pull request #6737: IGNITE-11944 [IEP-35] OpencensusExporter should export Histogram metrics URL: https://github.com/apache/ignite/pull/6737#discussion_r323213084
########## File path: modules/opencensus/src/main/java/org/apache/ignite/spi/metric/opencensus/OpenCensusMetricExporterSpi.java ########## @@ -118,6 +120,26 @@ */ private Map<String, Measure> measures = new HashMap<>(); + /** Cached histogram metrics intervals names. */ + private Map<T2<String, long[]>, String[]> histogramNames = new HashMap<>(); Review comment: Seems, a map is not cleared on `MetricRegistry` remove. It would be more efficient to make this map `Map<String, T2<long[], String[]>>` and use like that: ``` T2<long[], String[]> cached = histogramNames.get(name); if (cached.get1() == bounds) // Use cached names else // replace cached with new calculation ``` ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org With regards, Apache Git Services