You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@dubbo.apache.org by "c409998649 (via GitHub)" <gi...@apache.org> on 2023/04/21 01:41:53 UTC

[GitHub] [dubbo] c409998649 opened a new issue, #12153: dubbo 3.2 turn on metrics report error ArrayIndexOutOfBoundsException

c409998649 opened a new issue, #12153:
URL: https://github.com/apache/dubbo/issues/12153

   <!-- If you need to report a security issue please visit https://github.com/apache/dubbo/security/policy -->
   
   - [ ] I have searched the [issues](https://github.com/apache/dubbo/issues) of this repository and believe that this is not a duplicate.
   
   ### Environment
   
   * Dubbo version: 3.2.0
   * Operating System version: linux
   * Java version: jdk 1.8
   
   ### Steps to reproduce this issue
   
   1. turn on metrics 
     metrics:
       protocol: prometheus
       export-service-port: x0003
       enable-jvm: true
       enable-threadpool: true
       enable-registry: true
       enable-metadata: true
   2. pressure test 100 thread
   
   If there is an exception, please attach the exception trace:
   
   Caused by: java.lang.ArrayIndexOutOfBoundsException: null
   com.tdunning.math.stats.MergingDigest.merge(MergingDigest.java:381)
   com.tdunning.math.stats.MergingDigest.mergeNewValues(MergingDigest.java:363)
   com.tdunning.math.stats.MergingDigest.mergeNewValues(MergingDigest.java:353)
   com.tdunning.math.stats.MergingDigest.add(MergingDigest.java:259)
   com.tdunning.math.stats.MergingDigest.add(MergingDigest.java:251)
   com.tdunning.math.stats.AbstractTDigest.add(AbstractTDigest.java:129)
   org.apache.dubbo.metrics.aggregate.TimeWindowQuantile.add(TimeWindowQuantile.java:51)
   org.apache.dubbo.metrics.collector.AggregateMetricsCollector.onRTEvent(AggregateMetricsCollector.java:92)
   org.apache.dubbo.metrics.collector.AggregateMetricsCollector.onEvent(AggregateMetricsCollector.java:82)
   org.apache.dubbo.metrics.event.SimpleMetricsEventMulticaster.publishEvent(SimpleMetricsEventMulticaster.java:48)
   org.apache.dubbo.metrics.collector.sample.MethodMetricsSampler.lambda$rtConfigure$3(MethodMetricsSampler.java:61)
   org.apache.dubbo.metrics.collector.sample.SimpleMetricsCountSampler.addRT(SimpleMetricsCountSampler.java:120)
   org.apache.dubbo.metrics.filter.MethodMetricsInterceptor.rtTime(MethodMetricsInterceptor.java:97)
   org.apache.dubbo.metrics.filter.MethodMetricsInterceptor.onCompleted(MethodMetricsInterceptor.java:101)
   org.apache.dubbo.metrics.filter.MethodMetricsInterceptor.afterMethod(MethodMetricsInterceptor.java:58)
   org.apache.dubbo.metrics.filter.MetricsFilter.onResponse(MetricsFilter.java:64)
   org.apache.dubbo.rpc.cluster.filter.FilterChainBuilder$CallbackRegistrationInvoker.lambda$invoke$1(FilterChainBuilder.java:218)
   org.apache.dubbo.rpc.AsyncRpcResult.lambda$whenCompleteWithContext$0(AsyncRpcResult.java:228)
   java.util.concurrent.CompletableFuture.uniWhenComplete(CompletableFuture.java:774)
   java.util.concurrent.CompletableFuture.uniWhenCompleteStage(CompletableFuture.java:792)
   java.util.concurrent.CompletableFuture.whenComplete(CompletableFuture.java:2153)
   org.apache.dubbo.rpc.AsyncRpcResult.whenCompleteWithContext(AsyncRpcResult.java:224)
   org.apache.dubbo.rpc.cluster.filter.FilterChainBuilder$CallbackRegistrationInvoker.invoke(FilterChainBuilder.java:195)
   org.apache.dubbo.rpc.protocol.ReferenceCountInvokerWrapper.invoke(ReferenceCountInvokerWrapper.java:78)
   org.apache.dubbo.rpc.cluster.support.AbstractClusterInvoker.invokeWithContext(AbstractClusterInvoker.java:380)
   org.apache.dubbo.rpc.cluster.support.FailoverClusterInvoker.doInvoke(FailoverClusterInvoker.java:81)
   org.apache.dubbo.rpc.cluster.support.AbstractClusterInvoker.invoke(AbstractClusterInvoker.java:341)
   org.apache.dubbo.rpc.cluster.router.RouterSnapshotFilter.invoke(RouterSnapshotFilter.java:46)
   org.apache.dubbo.rpc.cluster.filter.FilterChainBuilder$CopyOfFilterChainNode.invoke(FilterChainBuilder.java:331)
   org.apache.dubbo.monitor.support.MonitorFilter.invoke$original$vkd7zZMh(MonitorFilter.java:101)
   org.apache.dubbo.monitor.support.MonitorFilter.invoke$original$vkd7zZMh$accessor$y8nuUX1o(MonitorFilter.java)
   org.apache.dubbo.monitor.support.MonitorFilter$auxiliary$YZgq7bd2.call(Unknown Source)
   org.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.InstMethodsInter.intercept(InstMethodsInter.java:86)
   org.apache.dubbo.monitor.support.MonitorFilter.invoke(MonitorFilter.java)
   org.apache.dubbo.rpc.cluster.filter.FilterChainBuilder$CopyOfFilterChainNode.invoke(FilterChainBuilder.java:331)
   org.apache.dubbo.rpc.cluster.filter.support.MetricsClusterFilter.invoke(MetricsClusterFilter.java:51)
   org.apache.dubbo.rpc.cluster.filter.FilterChainBuilder$CopyOfFilterChainNode.invoke(FilterChainBuilder.java:331)
   org.apache.dubbo.rpc.protocol.dubbo.filter.FutureFilter.invoke(FutureFilter.java:52)
   org.apache.dubbo.rpc.cluster.filter.FilterChainBuilder$CopyOfFilterChainNode.invoke(FilterChainBuilder.java:331)
   org.apache.dubbo.rpc.cluster.specifyaddress.AddressSpecifyClusterFilter.invoke(AddressSpecifyClusterFilter.java:40)
   org.apache.dubbo.rpc.cluster.filter.FilterChainBuilder$CopyOfFilterChainNode.invoke(FilterChainBuilder.java:331)
   org.apache.dubbo.spring.security.filter.ContextHolderParametersSelectedTransferFilter.invoke(ContextHolderParametersSelectedTransferFilter.java:41)
   org.apache.dubbo.rpc.cluster.filter.FilterChainBuilder$CopyOfFilterChainNode.invoke(FilterChainBuilder.java:331)
   org.apache.dubbo.rpc.cluster.filter.support.ConsumerClassLoaderFilter.invoke(ConsumerClassLoaderFilter.java:40)
   org.apache.dubbo.rpc.cluster.filter.FilterChainBuilder$CopyOfFilterChainNode.invoke(FilterChainBuilder.java:331)
   com.mea.pay.common.dubbo.DubboConsumerContextFilter.invoke(DubboConsumerContextFilter.java:90)
   org.apache.dubbo.rpc.cluster.filter.FilterChainBuilder$CopyOfFilterChainNode.invoke(FilterChainBuilder.java:331)
   org.apache.dubbo.rpc.cluster.filter.support.ConsumerContextFilter.invoke(ConsumerContextFilter.java:118)
   org.apache.dubbo.rpc.cluster.filter.FilterChainBuilder$CopyOfFilterChainNode.invoke(FilterChainBuilder.java:331)
   org.apache.dubbo.rpc.cluster.filter.FilterChainBuilder$CallbackRegistrationInvoker.invoke(FilterChainBuilder.java:194)
   org.apache.dubbo.rpc.cluster.support.wrapper.AbstractCluster$ClusterFilterInvoker.invoke(AbstractCluster.java:91)
   org.apache.dubbo.rpc.cluster.support.wrapper.MockClusterInvoker.invoke(MockClusterInvoker.java:103)
   com.mea.pay.common.dubbo.TagInvoker.invoke(TagInvoker.java:45)
   org.apache.dubbo.rpc.cluster.support.wrapper.ScopeClusterInvoker.invoke(ScopeClusterInvoker.java:131)
   org.apache.dubbo.registry.client.migration.MigrationInvoker.invoke(MigrationInvoker.java:284)
   \t... 91 common frames omitted
   


-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo] songxiaosheng commented on issue #12153: dubbo 3.2 turn on metrics report error ArrayIndexOutOfBoundsException

Posted by "songxiaosheng (via GitHub)" <gi...@apache.org>.
songxiaosheng commented on issue #12153:
URL: https://github.com/apache/dubbo/issues/12153#issuecomment-1517797620

   指标这里复用了qos的端口不需要开放其它端口了


-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo] c409998649 commented on issue #12153: dubbo 3.2 turn on metrics report error ArrayIndexOutOfBoundsException

Posted by "c409998649 (via GitHub)" <gi...@apache.org>.
c409998649 commented on issue #12153:
URL: https://github.com/apache/dubbo/issues/12153#issuecomment-1517288272

   onRTEvent(RTEvent event) 在并发的场景下 会出现ArrayIndexOutOfBoundsException的异常 但是没有拦截异常做处理 并且还会让本次dubbo调用失败


-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo] songxiaosheng closed issue #12153: dubbo 3.2 turn on metrics report error ArrayIndexOutOfBoundsException

Posted by "songxiaosheng (via GitHub)" <gi...@apache.org>.
songxiaosheng closed issue #12153: dubbo 3.2 turn on metrics report error ArrayIndexOutOfBoundsException
URL: https://github.com/apache/dubbo/issues/12153


-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo] songxiaosheng commented on issue #12153: dubbo 3.2 turn on metrics report error ArrayIndexOutOfBoundsException

Posted by "songxiaosheng (via GitHub)" <gi...@apache.org>.
songxiaosheng commented on issue #12153:
URL: https://github.com/apache/dubbo/issues/12153#issuecomment-1521109740

   > > histogram
   > 
   > 这个可以 那个聚合用的t-digest好像本身并发就有问题
   
   那个开关先不要开了,我们看看如何优化


-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo] c409998649 commented on issue #12153: dubbo 3.2 turn on metrics report error ArrayIndexOutOfBoundsException

Posted by "c409998649 (via GitHub)" <gi...@apache.org>.
c409998649 commented on issue #12153:
URL: https://github.com/apache/dubbo/issues/12153#issuecomment-1517845601

   > 指标这里复用了qos的端口不需要开放其它端口了
   
   哦  我还以为两个都必须要用


-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo] songxiaosheng commented on issue #12153: dubbo 3.2 turn on metrics report error ArrayIndexOutOfBoundsException

Posted by "songxiaosheng (via GitHub)" <gi...@apache.org>.
songxiaosheng commented on issue #12153:
URL: https://github.com/apache/dubbo/issues/12153#issuecomment-1517487062

   > <!-- If you need to report a security issue please visit https://github.com/apache/dubbo/security/policy -->
   > 
   > - [ ] I have searched the [issues](https://github.com/apache/dubbo/issues) of this repository and believe that this is not a duplicate.
   > 
   > ### Environment
   > 
   > * Dubbo version: 3.2.0
   > * Operating System version: linux
   > * Java version: jdk 1.8
   > 
   > ### Steps to reproduce this issue
   > 
   > 1. turn on metrics 
   >   metrics:
   >     protocol: prometheus
   >     export-service-port: x0003
   >     enable-jvm: true
   >     enable-threadpool: true
   >     enable-registry: true
   >     enable-metadata: true
   > 2. pressure test 100 thread
   > 
   > If there is an exception, please attach the exception trace:
   > 
   > Caused by: java.lang.ArrayIndexOutOfBoundsException: null
   > com.tdunning.math.stats.MergingDigest.merge(MergingDigest.java:381)
   > com.tdunning.math.stats.MergingDigest.mergeNewValues(MergingDigest.java:363)
   > com.tdunning.math.stats.MergingDigest.mergeNewValues(MergingDigest.java:353)
   > com.tdunning.math.stats.MergingDigest.add(MergingDigest.java:259)
   > com.tdunning.math.stats.MergingDigest.add(MergingDigest.java:251)
   > com.tdunning.math.stats.AbstractTDigest.add(AbstractTDigest.java:129)
   > org.apache.dubbo.metrics.aggregate.TimeWindowQuantile.add(TimeWindowQuantile.java:51)
   > org.apache.dubbo.metrics.collector.AggregateMetricsCollector.onRTEvent(AggregateMetricsCollector.java:92)
   > org.apache.dubbo.metrics.collector.AggregateMetricsCollector.onEvent(AggregateMetricsCollector.java:82)
   > org.apache.dubbo.metrics.event.SimpleMetricsEventMulticaster.publishEvent(SimpleMetricsEventMulticaster.java:48)
   > org.apache.dubbo.metrics.collector.sample.MethodMetricsSampler.lambda$rtConfigure$3(MethodMetricsSampler.java:61)
   > org.apache.dubbo.metrics.collector.sample.SimpleMetricsCountSampler.addRT(SimpleMetricsCountSampler.java:120)
   > org.apache.dubbo.metrics.filter.MethodMetricsInterceptor.rtTime(MethodMetricsInterceptor.java:97)
   > org.apache.dubbo.metrics.filter.MethodMetricsInterceptor.onCompleted(MethodMetricsInterceptor.java:101)
   > org.apache.dubbo.metrics.filter.MethodMetricsInterceptor.afterMethod(MethodMetricsInterceptor.java:58)
   > org.apache.dubbo.metrics.filter.MetricsFilter.onResponse(MetricsFilter.java:64)
   > org.apache.dubbo.rpc.cluster.filter.FilterChainBuilder$CallbackRegistrationInvoker.lambda$invoke$1(FilterChainBuilder.java:218)
   > org.apache.dubbo.rpc.AsyncRpcResult.lambda$whenCompleteWithContext$0(AsyncRpcResult.java:228)
   > java.util.concurrent.CompletableFuture.uniWhenComplete(CompletableFuture.java:774)
   > java.util.concurrent.CompletableFuture.uniWhenCompleteStage(CompletableFuture.java:792)
   > java.util.concurrent.CompletableFuture.whenComplete(CompletableFuture.java:2153)
   > org.apache.dubbo.rpc.AsyncRpcResult.whenCompleteWithContext(AsyncRpcResult.java:224)
   > org.apache.dubbo.rpc.cluster.filter.FilterChainBuilder$CallbackRegistrationInvoker.invoke(FilterChainBuilder.java:195)
   > org.apache.dubbo.rpc.protocol.ReferenceCountInvokerWrapper.invoke(ReferenceCountInvokerWrapper.java:78)
   > org.apache.dubbo.rpc.cluster.support.AbstractClusterInvoker.invokeWithContext(AbstractClusterInvoker.java:380)
   > org.apache.dubbo.rpc.cluster.support.FailoverClusterInvoker.doInvoke(FailoverClusterInvoker.java:81)
   > org.apache.dubbo.rpc.cluster.support.AbstractClusterInvoker.invoke(AbstractClusterInvoker.java:341)
   > org.apache.dubbo.rpc.cluster.router.RouterSnapshotFilter.invoke(RouterSnapshotFilter.java:46)
   > org.apache.dubbo.rpc.cluster.filter.FilterChainBuilder$CopyOfFilterChainNode.invoke(FilterChainBuilder.java:331)
   > org.apache.dubbo.monitor.support.MonitorFilter.invoke$original$vkd7zZMh(MonitorFilter.java:101)
   > org.apache.dubbo.monitor.support.MonitorFilter.invoke$original$vkd7zZMh$accessor$y8nuUX1o(MonitorFilter.java)
   > org.apache.dubbo.monitor.support.MonitorFilter$auxiliary$YZgq7bd2.call(Unknown Source)
   > org.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.InstMethodsInter.intercept(InstMethodsInter.java:86)
   > org.apache.dubbo.monitor.support.MonitorFilter.invoke(MonitorFilter.java)
   > org.apache.dubbo.rpc.cluster.filter.FilterChainBuilder$CopyOfFilterChainNode.invoke(FilterChainBuilder.java:331)
   > org.apache.dubbo.rpc.cluster.filter.support.MetricsClusterFilter.invoke(MetricsClusterFilter.java:51)
   > org.apache.dubbo.rpc.cluster.filter.FilterChainBuilder$CopyOfFilterChainNode.invoke(FilterChainBuilder.java:331)
   > org.apache.dubbo.rpc.protocol.dubbo.filter.FutureFilter.invoke(FutureFilter.java:52)
   > org.apache.dubbo.rpc.cluster.filter.FilterChainBuilder$CopyOfFilterChainNode.invoke(FilterChainBuilder.java:331)
   > org.apache.dubbo.rpc.cluster.specifyaddress.AddressSpecifyClusterFilter.invoke(AddressSpecifyClusterFilter.java:40)
   > org.apache.dubbo.rpc.cluster.filter.FilterChainBuilder$CopyOfFilterChainNode.invoke(FilterChainBuilder.java:331)
   > org.apache.dubbo.spring.security.filter.ContextHolderParametersSelectedTransferFilter.invoke(ContextHolderParametersSelectedTransferFilter.java:41)
   > org.apache.dubbo.rpc.cluster.filter.FilterChainBuilder$CopyOfFilterChainNode.invoke(FilterChainBuilder.java:331)
   > org.apache.dubbo.rpc.cluster.filter.support.ConsumerClassLoaderFilter.invoke(ConsumerClassLoaderFilter.java:40)
   > org.apache.dubbo.rpc.cluster.filter.FilterChainBuilder$CopyOfFilterChainNode.invoke(FilterChainBuilder.java:331)
   > com.mea.pay.common.dubbo.DubboConsumerContextFilter.invoke(DubboConsumerContextFilter.java:90)
   > org.apache.dubbo.rpc.cluster.filter.FilterChainBuilder$CopyOfFilterChainNode.invoke(FilterChainBuilder.java:331)
   > org.apache.dubbo.rpc.cluster.filter.support.ConsumerContextFilter.invoke(ConsumerContextFilter.java:118)
   > org.apache.dubbo.rpc.cluster.filter.FilterChainBuilder$CopyOfFilterChainNode.invoke(FilterChainBuilder.java:331)
   > org.apache.dubbo.rpc.cluster.filter.FilterChainBuilder$CallbackRegistrationInvoker.invoke(FilterChainBuilder.java:194)
   > org.apache.dubbo.rpc.cluster.support.wrapper.AbstractCluster$ClusterFilterInvoker.invoke(AbstractCluster.java:91)
   > org.apache.dubbo.rpc.cluster.support.wrapper.MockClusterInvoker.invoke(MockClusterInvoker.java:103)
   > com.mea.pay.common.dubbo.TagInvoker.invoke(TagInvoker.java:45)
   > org.apache.dubbo.rpc.cluster.support.wrapper.ScopeClusterInvoker.invoke(ScopeClusterInvoker.java:131)
   > org.apache.dubbo.registry.client.migration.MigrationInvoker.invoke(MigrationInvoker.java:284)
   > \t... 91 common frames omitted
   > 
   
   是否可以先通过aggregation开关配置关闭掉聚合数据,聚合数据并发的问题我们处理下


-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo] c409998649 commented on issue #12153: dubbo 3.2 turn on metrics report error ArrayIndexOutOfBoundsException

Posted by "c409998649 (via GitHub)" <gi...@apache.org>.
c409998649 commented on issue #12153:
URL: https://github.com/apache/dubbo/issues/12153#issuecomment-1521087740

   > histogram
   
   这个可以 那个聚合用的t-digest好像本身并发就有问题


-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo] songxiaosheng commented on issue #12153: dubbo 3.2 turn on metrics report error ArrayIndexOutOfBoundsException

Posted by "songxiaosheng (via GitHub)" <gi...@apache.org>.
songxiaosheng commented on issue #12153:
URL: https://github.com/apache/dubbo/issues/12153#issuecomment-1517896330

   > > 指标这里复用了qos的端口不需要开放其它端口了
   > 
   > 哦  我还以为两个都必须要用
   
   在哪里看到的 我看看是不是文档有问题


-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo] c409998649 commented on issue #12153: dubbo 3.2 turn on metrics report error ArrayIndexOutOfBoundsException

Posted by "c409998649 (via GitHub)" <gi...@apache.org>.
c409998649 commented on issue #12153:
URL: https://github.com/apache/dubbo/issues/12153#issuecomment-1517626534

   > > * [ ]  I have searched the [issues](https://github.com/apache/dubbo/issues) of this repository and believe that this is not a duplicate.
   > > 
   > > ### Environment
   > > 
   > > * Dubbo version: 3.2.0
   > > * Operating System version: linux
   > > * Java version: jdk 1.8
   > > 
   > > ### Steps to reproduce this issue
   > > 
   > > 1. turn on metrics
   > >    metrics:
   > >    protocol: prometheus
   > >    export-service-port: x0003
   > >    enable-jvm: true
   > >    enable-threadpool: true
   > >    enable-registry: true
   > >    enable-metadata: true
   > > 2. pressure test 100 thread
   > > 
   > > If there is an exception, please attach the exception trace:
   > > Caused by: java.lang.ArrayIndexOutOfBoundsException: null
   > > com.tdunning.math.stats.MergingDigest.merge(MergingDigest.java:381)
   > > com.tdunning.math.stats.MergingDigest.mergeNewValues(MergingDigest.java:363)
   > > com.tdunning.math.stats.MergingDigest.mergeNewValues(MergingDigest.java:353)
   > > com.tdunning.math.stats.MergingDigest.add(MergingDigest.java:259)
   > > com.tdunning.math.stats.MergingDigest.add(MergingDigest.java:251)
   > > com.tdunning.math.stats.AbstractTDigest.add(AbstractTDigest.java:129)
   > > org.apache.dubbo.metrics.aggregate.TimeWindowQuantile.add(TimeWindowQuantile.java:51)
   > > org.apache.dubbo.metrics.collector.AggregateMetricsCollector.onRTEvent(AggregateMetricsCollector.java:92)
   > > org.apache.dubbo.metrics.collector.AggregateMetricsCollector.onEvent(AggregateMetricsCollector.java:82)
   > > org.apache.dubbo.metrics.event.SimpleMetricsEventMulticaster.publishEvent(SimpleMetricsEventMulticaster.java:48)
   > > org.apache.dubbo.metrics.collector.sample.MethodMetricsSampler.lambda$rtConfigure$3(MethodMetricsSampler.java:61)
   > > org.apache.dubbo.metrics.collector.sample.SimpleMetricsCountSampler.addRT(SimpleMetricsCountSampler.java:120)
   > > org.apache.dubbo.metrics.filter.MethodMetricsInterceptor.rtTime(MethodMetricsInterceptor.java:97)
   > > org.apache.dubbo.metrics.filter.MethodMetricsInterceptor.onCompleted(MethodMetricsInterceptor.java:101)
   > > org.apache.dubbo.metrics.filter.MethodMetricsInterceptor.afterMethod(MethodMetricsInterceptor.java:58)
   > > org.apache.dubbo.metrics.filter.MetricsFilter.onResponse(MetricsFilter.java:64)
   > > org.apache.dubbo.rpc.cluster.filter.FilterChainBuilder$CallbackRegistrationInvoker.lambda$invoke$1(FilterChainBuilder.java:218)
   > > org.apache.dubbo.rpc.AsyncRpcResult.lambda$whenCompleteWithContext$0(AsyncRpcResult.java:228)
   > > java.util.concurrent.CompletableFuture.uniWhenComplete(CompletableFuture.java:774)
   > > java.util.concurrent.CompletableFuture.uniWhenCompleteStage(CompletableFuture.java:792)
   > > java.util.concurrent.CompletableFuture.whenComplete(CompletableFuture.java:2153)
   > > org.apache.dubbo.rpc.AsyncRpcResult.whenCompleteWithContext(AsyncRpcResult.java:224)
   > > org.apache.dubbo.rpc.cluster.filter.FilterChainBuilder$CallbackRegistrationInvoker.invoke(FilterChainBuilder.java:195)
   > > org.apache.dubbo.rpc.protocol.ReferenceCountInvokerWrapper.invoke(ReferenceCountInvokerWrapper.java:78)
   > > org.apache.dubbo.rpc.cluster.support.AbstractClusterInvoker.invokeWithContext(AbstractClusterInvoker.java:380)
   > > org.apache.dubbo.rpc.cluster.support.FailoverClusterInvoker.doInvoke(FailoverClusterInvoker.java:81)
   > > org.apache.dubbo.rpc.cluster.support.AbstractClusterInvoker.invoke(AbstractClusterInvoker.java:341)
   > > org.apache.dubbo.rpc.cluster.router.RouterSnapshotFilter.invoke(RouterSnapshotFilter.java:46)
   > > org.apache.dubbo.rpc.cluster.filter.FilterChainBuilder$CopyOfFilterChainNode.invoke(FilterChainBuilder.java:331)
   > > org.apache.dubbo.monitor.support.MonitorFilter.invoke$original$vkd7zZMh(MonitorFilter.java:101)
   > > org.apache.dubbo.monitor.support.MonitorFilter.invoke$original$vkd7zZMh$accessor$y8nuUX1o(MonitorFilter.java)
   > > org.apache.dubbo.monitor.support.MonitorFilter$auxiliary$YZgq7bd2.call(Unknown Source)
   > > org.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.InstMethodsInter.intercept(InstMethodsInter.java:86)
   > > org.apache.dubbo.monitor.support.MonitorFilter.invoke(MonitorFilter.java)
   > > org.apache.dubbo.rpc.cluster.filter.FilterChainBuilder$CopyOfFilterChainNode.invoke(FilterChainBuilder.java:331)
   > > org.apache.dubbo.rpc.cluster.filter.support.MetricsClusterFilter.invoke(MetricsClusterFilter.java:51)
   > > org.apache.dubbo.rpc.cluster.filter.FilterChainBuilder$CopyOfFilterChainNode.invoke(FilterChainBuilder.java:331)
   > > org.apache.dubbo.rpc.protocol.dubbo.filter.FutureFilter.invoke(FutureFilter.java:52)
   > > org.apache.dubbo.rpc.cluster.filter.FilterChainBuilder$CopyOfFilterChainNode.invoke(FilterChainBuilder.java:331)
   > > org.apache.dubbo.rpc.cluster.specifyaddress.AddressSpecifyClusterFilter.invoke(AddressSpecifyClusterFilter.java:40)
   > > org.apache.dubbo.rpc.cluster.filter.FilterChainBuilder$CopyOfFilterChainNode.invoke(FilterChainBuilder.java:331)
   > > org.apache.dubbo.spring.security.filter.ContextHolderParametersSelectedTransferFilter.invoke(ContextHolderParametersSelectedTransferFilter.java:41)
   > > org.apache.dubbo.rpc.cluster.filter.FilterChainBuilder$CopyOfFilterChainNode.invoke(FilterChainBuilder.java:331)
   > > org.apache.dubbo.rpc.cluster.filter.support.ConsumerClassLoaderFilter.invoke(ConsumerClassLoaderFilter.java:40)
   > > org.apache.dubbo.rpc.cluster.filter.FilterChainBuilder$CopyOfFilterChainNode.invoke(FilterChainBuilder.java:331)
   > > com.mea.pay.common.dubbo.DubboConsumerContextFilter.invoke(DubboConsumerContextFilter.java:90)
   > > org.apache.dubbo.rpc.cluster.filter.FilterChainBuilder$CopyOfFilterChainNode.invoke(FilterChainBuilder.java:331)
   > > org.apache.dubbo.rpc.cluster.filter.support.ConsumerContextFilter.invoke(ConsumerContextFilter.java:118)
   > > org.apache.dubbo.rpc.cluster.filter.FilterChainBuilder$CopyOfFilterChainNode.invoke(FilterChainBuilder.java:331)
   > > org.apache.dubbo.rpc.cluster.filter.FilterChainBuilder$CallbackRegistrationInvoker.invoke(FilterChainBuilder.java:194)
   > > org.apache.dubbo.rpc.cluster.support.wrapper.AbstractCluster$ClusterFilterInvoker.invoke(AbstractCluster.java:91)
   > > org.apache.dubbo.rpc.cluster.support.wrapper.MockClusterInvoker.invoke(MockClusterInvoker.java:103)
   > > com.mea.pay.common.dubbo.TagInvoker.invoke(TagInvoker.java:45)
   > > org.apache.dubbo.rpc.cluster.support.wrapper.ScopeClusterInvoker.invoke(ScopeClusterInvoker.java:131)
   > > org.apache.dubbo.registry.client.migration.MigrationInvoker.invoke(MigrationInvoker.java:284)
   > > \t... 91 common frames omitted
   > 
   > 是否可以先通过aggregation开关配置关闭掉聚合数据,聚合数据并发的问题我们处理下
   
   可以关闭,还有个问题
   dubbo:
     application:
       register-mode: instance
       qos-port: ${dubbo.metrics.export-service-port}
       qos-accept-foreign-ip-whitelist: 192.168.110.141
     metrics:
       protocol: prometheus
       export-service-port: 40001
       enable-jvm: true
       enable-threadpool: true
       enable-registry: true
       enable-metadata: true
       aggregation:
         enabled: false
   会出现一个Failed to bind NettyPortUnificationServer on /0.0.0.0:40001, cause: 地址已在使用的错误


-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo] c409998649 commented on issue #12153: dubbo 3.2 turn on metrics report error ArrayIndexOutOfBoundsException

Posted by "c409998649 (via GitHub)" <gi...@apache.org>.
c409998649 commented on issue #12153:
URL: https://github.com/apache/dubbo/issues/12153#issuecomment-1517215715

   q should be in [0,1], got 22.0 add(double value) value为22.0的情况下就会出现bug


-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo] c409998649 commented on issue #12153: dubbo 3.2 turn on metrics report error ArrayIndexOutOfBoundsException

Posted by "c409998649 (via GitHub)" <gi...@apache.org>.
c409998649 commented on issue #12153:
URL: https://github.com/apache/dubbo/issues/12153#issuecomment-1517913530

   > > > 指标这里复用了qos的端口不需要开放其它端口了
   > > 
   > > 
   > > 哦  我还以为两个都必须要用
   > 
   > 在哪里看到的 我看看是不是文档有问题
   
   没有问题了 我前几天看到dubbo-samples 实例里面写了那个端口 我刚刚去看已经去掉了


-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo] songxiaosheng commented on issue #12153: dubbo 3.2 turn on metrics report error ArrayIndexOutOfBoundsException

Posted by "songxiaosheng (via GitHub)" <gi...@apache.org>.
songxiaosheng commented on issue #12153:
URL: https://github.com/apache/dubbo/issues/12153#issuecomment-1520375100

   你那边是否可以尝试使用直方图开关项:<dubbo:histogram enabled="true"/> 而不是使用聚合指标进行测试:
   
   最近5分钟某个方法的平均时间如下:
   rate(dubbo_provider_rt_milliseconds_histogram_seconds_count{interface="org.apache.dubbo.samples.metrics.prometheus.api.DemoService",method="randomResponseTime"}[5m])  /rate(dubbo_provider_rt_milliseconds_histogram_seconds_sum{interface="org.apache.dubbo.samples.metrics.prometheus.api.DemoService",method="randomResponseTime"}[5m]) 
   
   效果如下图:
   
   ![image](https://user-images.githubusercontent.com/81170548/234040700-3f7079e3-63e2-43bb-b1d3-053358dec240.png)
   


-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org