[jira] [Commented] (IGNITE-12769) MetricRegistryMBean and OpenCensusExporterSpi have memory leak
[ https://issues.apache.org/jira/browse/IGNITE-12769?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17065898#comment-17065898 ] Andrey N. Gura commented on IGNITE-12769: - [~nizhikov] LGTM. Thanks for this fix. I think IGNITE-12767 could be also resolved. Please, proceed with merge. > MetricRegistryMBean and OpenCensusExporterSpi have memory leak > -- > > Key: IGNITE-12769 > URL: https://issues.apache.org/jira/browse/IGNITE-12769 > Project: Ignite > Issue Type: Bug >Reporter: Andrey N. Gura >Assignee: Nikolay Izhikov >Priority: Major > Labels: IEP-35 > Fix For: 2.8.1 > > Time Spent: 10m > Remaining Estimate: 0h > > {{MetricRegistryMBean}} and {{OpenCensusExporterSpi}} have memory leak. > To the following maps values add but never remove (i.e. on remove > corresponding histogram or on change histogram buckets layout): > * {{MetricRegistryMBean.histogramNames}} > * {{OpenCensusMetricExporterSpi.histogramNames}} -- This message was sent by Atlassian Jira (v8.3.4#803005)
[jira] [Commented] (IGNITE-12769) MetricRegistryMBean and OpenCensusExporterSpi have memory leak
[ https://issues.apache.org/jira/browse/IGNITE-12769?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17063389#comment-17063389 ] Nikolay Izhikov commented on IGNITE-12769: -- [~agura] I got bot visa. Please, review. > MetricRegistryMBean and OpenCensusExporterSpi have memory leak > -- > > Key: IGNITE-12769 > URL: https://issues.apache.org/jira/browse/IGNITE-12769 > Project: Ignite > Issue Type: Bug >Reporter: Andrey N. Gura >Assignee: Nikolay Izhikov >Priority: Major > Fix For: 2.8.1 > > Time Spent: 10m > Remaining Estimate: 0h > > {{MetricRegistryMBean}} and {{OpenCensusExporterSpi}} have memory leak. > To the following maps values add but never remove (i.e. on remove > corresponding histogram or on change histogram buckets layout): > * {{MetricRegistryMBean.histogramNames}} > * {{OpenCensusMetricExporterSpi.histogramNames}} -- This message was sent by Atlassian Jira (v8.3.4#803005)
[jira] [Commented] (IGNITE-12769) MetricRegistryMBean and OpenCensusExporterSpi have memory leak
[ https://issues.apache.org/jira/browse/IGNITE-12769?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17063387#comment-17063387 ] Ignite TC Bot commented on IGNITE-12769: {panel:title=Branch: [pull/7549/head] Base: [master] : No blockers found!|borderStyle=dashed|borderColor=#ccc|titleBGColor=#D6F7C1}{panel} [TeamCity *-- Run :: All* Results|https://ci.ignite.apache.org/viewLog.html?buildId=5143604buildTypeId=IgniteTests24Java8_RunAll] > MetricRegistryMBean and OpenCensusExporterSpi have memory leak > -- > > Key: IGNITE-12769 > URL: https://issues.apache.org/jira/browse/IGNITE-12769 > Project: Ignite > Issue Type: Bug >Reporter: Andrey N. Gura >Assignee: Nikolay Izhikov >Priority: Major > Fix For: 2.8.1 > > Time Spent: 10m > Remaining Estimate: 0h > > {{MetricRegistryMBean}} and {{OpenCensusExporterSpi}} have memory leak. > To the following maps values add but never remove (i.e. on remove > corresponding histogram or on change histogram buckets layout): > * {{MetricRegistryMBean.histogramNames}} > * {{OpenCensusMetricExporterSpi.histogramNames}} -- This message was sent by Atlassian Jira (v8.3.4#803005)
[jira] [Commented] (IGNITE-12769) MetricRegistryMBean and OpenCensusExporterSpi have memory leak
[ https://issues.apache.org/jira/browse/IGNITE-12769?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17063288#comment-17063288 ] Ignite TC Bot commented on IGNITE-12769: {panel:title=Branch: [pull/7549/head] Base: [master] : Possible Blockers (2)|borderStyle=dashed|borderColor=#ccc|titleBGColor=#F7D6C1} {color:#d04437}PDS (Indexing){color} [[tests 0 TIMEOUT , Exit Code |https://ci.ignite.apache.org/viewLog.html?buildId=5142921]] {color:#d04437}Cache 6{color} [[tests 0 Exit Code |https://ci.ignite.apache.org/viewLog.html?buildId=5142911]] {panel} [TeamCity *-- Run :: All* Results|https://ci.ignite.apache.org/viewLog.html?buildId=5142957buildTypeId=IgniteTests24Java8_RunAll] > MetricRegistryMBean and OpenCensusExporterSpi have memory leak > -- > > Key: IGNITE-12769 > URL: https://issues.apache.org/jira/browse/IGNITE-12769 > Project: Ignite > Issue Type: Bug >Reporter: Andrey N. Gura >Assignee: Nikolay Izhikov >Priority: Major > Fix For: 2.8.1 > > Time Spent: 10m > Remaining Estimate: 0h > > {{MetricRegistryMBean}} and {{OpenCensusExporterSpi}} have memory leak. > To the following maps values add but never remove (i.e. on remove > corresponding histogram or on change histogram buckets layout): > * {{MetricRegistryMBean.histogramNames}} > * {{OpenCensusMetricExporterSpi.histogramNames}} -- This message was sent by Atlassian Jira (v8.3.4#803005)
[jira] [Commented] (IGNITE-12769) MetricRegistryMBean and OpenCensusExporterSpi have memory leak
[ https://issues.apache.org/jira/browse/IGNITE-12769?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17062664#comment-17062664 ] Nikolay Izhikov commented on IGNITE-12769: -- [~agura] Sorry, for that. I've removed unused imports. I also checked both OpenCensusMetricExporterSpiTest and JmxExporterSpiTest and it's ok. Run all - https://ci.ignite.apache.org/viewQueued.html?itemId=5140069=queuedBuildOverviewTab Do you think absence of the visa is blocking review? > MetricRegistryMBean and OpenCensusExporterSpi have memory leak > -- > > Key: IGNITE-12769 > URL: https://issues.apache.org/jira/browse/IGNITE-12769 > Project: Ignite > Issue Type: Bug >Reporter: Andrey N. Gura >Assignee: Nikolay Izhikov >Priority: Major > Fix For: 2.8.1 > > Time Spent: 10m > Remaining Estimate: 0h > > {{MetricRegistryMBean}} and {{OpenCensusExporterSpi}} have memory leak. > To the following maps values add but never remove (i.e. on remove > corresponding histogram or on change histogram buckets layout): > * {{MetricRegistryMBean.histogramNames}} > * {{OpenCensusMetricExporterSpi.histogramNames}} -- This message was sent by Atlassian Jira (v8.3.4#803005)
[jira] [Commented] (IGNITE-12769) MetricRegistryMBean and OpenCensusExporterSpi have memory leak
[ https://issues.apache.org/jira/browse/IGNITE-12769?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17062651#comment-17062651 ] Andrey N. Gura commented on IGNITE-12769: - [~nizhikov] Could you please get TC bot visa first? At least now check style fails due to unused imports. > MetricRegistryMBean and OpenCensusExporterSpi have memory leak > -- > > Key: IGNITE-12769 > URL: https://issues.apache.org/jira/browse/IGNITE-12769 > Project: Ignite > Issue Type: Bug >Reporter: Andrey N. Gura >Assignee: Nikolay Izhikov >Priority: Major > Fix For: 2.8.1 > > Time Spent: 10m > Remaining Estimate: 0h > > {{MetricRegistryMBean}} and {{OpenCensusExporterSpi}} have memory leak. > To the following maps values add but never remove (i.e. on remove > corresponding histogram or on change histogram buckets layout): > * {{MetricRegistryMBean.histogramNames}} > * {{OpenCensusMetricExporterSpi.histogramNames}} -- This message was sent by Atlassian Jira (v8.3.4#803005)
[jira] [Commented] (IGNITE-12769) MetricRegistryMBean and OpenCensusExporterSpi have memory leak
[ https://issues.apache.org/jira/browse/IGNITE-12769?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17061937#comment-17061937 ] Nikolay Izhikov commented on IGNITE-12769: -- [~agura] Can you, please, take a look at my changes https://github.com/apache/ignite/pull/7549/files > MetricRegistryMBean and OpenCensusExporterSpi have memory leak > -- > > Key: IGNITE-12769 > URL: https://issues.apache.org/jira/browse/IGNITE-12769 > Project: Ignite > Issue Type: Bug >Reporter: Andrey N. Gura >Assignee: Nikolay Izhikov >Priority: Major > Fix For: 2.8.1 > > Time Spent: 10m > Remaining Estimate: 0h > > {{MetricRegistryMBean}} and {{OpenCensusExporterSpi}} have memory leak. > To the following maps values add but never remove (i.e. on remove > corresponding histogram or on change histogram buckets layout): > * {{MetricRegistryMBean.histogramNames}} > * {{OpenCensusMetricExporterSpi.histogramNames}} -- This message was sent by Atlassian Jira (v8.3.4#803005)
[jira] [Commented] (IGNITE-12769) MetricRegistryMBean and OpenCensusExporterSpi have memory leak
[ https://issues.apache.org/jira/browse/IGNITE-12769?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17061932#comment-17061932 ] Nikolay Izhikov commented on IGNITE-12769: -- [~agura] > For MetricRegistryMBean each invocation of getAttribute attribute method > will still produce garbage which is comparable with concatenation of metric > name and bounds. Ok, let's remove histogramNames cache from the MetricRegistryMBean. > MetricRegistryMBean and OpenCensusExporterSpi have memory leak > -- > > Key: IGNITE-12769 > URL: https://issues.apache.org/jira/browse/IGNITE-12769 > Project: Ignite > Issue Type: Bug >Reporter: Andrey N. Gura >Assignee: Nikolay Izhikov >Priority: Major > Fix For: 2.8.1 > > > {{MetricRegistryMBean}} and {{OpenCensusExporterSpi}} have memory leak. > To the following maps values add but never remove (i.e. on remove > corresponding histogram or on change histogram buckets layout): > * {{MetricRegistryMBean.histogramNames}} > * {{OpenCensusMetricExporterSpi.histogramNames}} -- This message was sent by Atlassian Jira (v8.3.4#803005)
[jira] [Commented] (IGNITE-12769) MetricRegistryMBean and OpenCensusExporterSpi have memory leak
[ https://issues.apache.org/jira/browse/IGNITE-12769?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17061788#comment-17061788 ] Andrey N. Gura commented on IGNITE-12769: - [~nizhikov] {{MetricRegistry}} still allows to remove any metrics. If somebody remove histogram metric {{histrogramNames}} caches will still contain key-value pair for removed histogram. I don't see any reason for {{histogramNames}} cache at all. For {{MetricRegistryMBean}} each invocation of {{getAttribute}} attribute method will still produce garbage which is comparable with concatenation of metric name and bounds. If we remove this cache we will also fix IGNITE-12767 automatically. Moreover, we will fix design problem where {{MetricUtils}} is responsible for histogram metric name representation instead of corresponding exporter. > MetricRegistryMBean and OpenCensusExporterSpi have memory leak > -- > > Key: IGNITE-12769 > URL: https://issues.apache.org/jira/browse/IGNITE-12769 > Project: Ignite > Issue Type: Bug >Reporter: Andrey N. Gura >Assignee: Nikolay Izhikov >Priority: Major > Fix For: 2.8.1 > > > {{MetricRegistryMBean}} and {{OpenCensusExporterSpi}} have memory leak. > To the following maps values add but never remove (i.e. on remove > corresponding histogram or on change histogram buckets layout): > * {{MetricRegistryMBean.histogramNames}} > * {{OpenCensusMetricExporterSpi.histogramNames}} -- This message was sent by Atlassian Jira (v8.3.4#803005)
[jira] [Commented] (IGNITE-12769) MetricRegistryMBean and OpenCensusExporterSpi have memory leak
[ https://issues.apache.org/jira/browse/IGNITE-12769?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17061771#comment-17061771 ] Nikolay Izhikov commented on IGNITE-12769: -- [~agura] It seems to me that this issue is invalid. {OpenCensusMetricExporterSpi} and {MetricRegistryMBean} keeps up to date {histogramNames} cache. I want to close this ticket as "Not a Problem". What do you think? 1. On the {MetricRegistry} removal all cache for OpenCensus exporter will be cleared in {code:java} /** {@inheritDoc} */ @Override public void spiStart(@Nullable String igniteInstanceName) throws IgniteSpiException { // mreg.addMetricRegistryRemoveListener(mreg -> mreg.forEach(metric -> histogramNames.remove(metric.name(; } {code} 2. On the {MetricRegistry} removal bean for JMX will be unregistered therefore it will be collected by GC: {code:java} /** {@inheritDoc} */ @Override public void spiStart(@Nullable String igniteInstanceName) throws IgniteSpiException { // mreg.addMetricRegistryRemoveListener(this::unregister); } {code} 3. On the configuration change cache for the specific histogram will be refreshed in(this applies to the both - JMX and OpenCencus exporters). {code:java} public static String[] histogramBucketNames(HistogramMetric metric, Map> cache) { // T2 tuple = cache.get(name); if (tuple != null && tuple.get1() == bounds) //bounds will be changed on configu change. return tuple.get2(); // cache.put(name, new T2<>(bounds, names)); //Cache refresh. return names; } {code} > MetricRegistryMBean and OpenCensusExporterSpi have memory leak > -- > > Key: IGNITE-12769 > URL: https://issues.apache.org/jira/browse/IGNITE-12769 > Project: Ignite > Issue Type: Bug >Reporter: Andrey N. Gura >Assignee: Nikolay Izhikov >Priority: Major > Fix For: 2.8.1 > > > {{MetricRegistryMBean}} and {{OpenCensusExporterSpi}} have memory leak. > To the following maps values add but never remove (i.e. on remove > corresponding histogram or on change histogram buckets layout): > * {{MetricRegistryMBean.histogramNames}} > * {{OpenCensusMetricExporterSpi.histogramNames}} -- This message was sent by Atlassian Jira (v8.3.4#803005)