You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@druid.apache.org by GitBox <gi...@apache.org> on 2021/04/01 12:20:50 UTC

[GitHub] [druid] johnynainwani commented on issue #4826: AvaticaClientRuntimeException: Remote driver error: IllegalStateException: DefaultQueryMetrics must not be modified from multiple threads.

johnynainwani commented on issue #4826:
URL: https://github.com/apache/druid/issues/4826#issuecomment-811868158


   I am also experiencing same issue in 0.20.1, while having a union of two "group by"s. Stack-trace is given as below.
   
   **ERROR**
   ### Error querying database. Cause: AvaticaClientRuntimeException: Remote driver error: IllegalStateException: DefaultQueryMetrics must not be modified from multiple threads. If it is needed to gather dimension or metric information from multiple threads or from an async thread, this information should explicitly be passed between threads (e. g. using Futures), or this DefaultQueryMetrics's ownerThread should be reassigned explicitly. Error -1 (00000) UNKNOWN
   
   java.lang.IllegalStateException: DefaultQueryMetrics must not be modified from multiple threads. If it is needed to gather dimension or metric information from multiple threads or from an async thread, this information should explicitly be passed between threads (e. g. using Futures), or this DefaultQueryMetrics's ownerThread should be reassigned explicitly
   at org.apache.druid.query.DefaultQueryMetrics.checkModifiedFromOwnerThread(DefaultQueryMetrics.java:67)
   at org.apache.druid.query.DefaultQueryMetrics.reportMetric(DefaultQueryMetrics.java:354)
   at org.apache.druid.query.DefaultQueryMetrics.reportCpuTime(DefaultQueryMetrics.java:251)
   at org.apache.druid.query.CPUTimeMetricQueryRunner$1.after(CPUTimeMetricQueryRunner.java:92)
   at org.apache.druid.java.util.common.guava.WrappingYielder.close(WrappingYielder.java:98)
   at org.apache.druid.java.util.common.guava.WrappingYielder.close(WrappingYielder.java:82)
   at org.apache.druid.java.util.common.guava.ConcatSequence.wrapYielder(ConcatSequence.java:112)
   at org.apache.druid.java.util.common.guava.ConcatSequence.access$000(ConcatSequence.java:27)
   at org.apache.druid.java.util.common.guava.ConcatSequence$2.next(ConcatSequence.java:132)
   at org.apache.druid.sql.avatica.DruidStatement.nextFrame(DruidStatement.java:274)
   at org.apache.druid.sql.avatica.DruidMeta.fetch(DruidMeta.java:238)
   at org.apache.calcite.avatica.remote.LocalService.apply(LocalService.java:239)
   at org.apache.calcite.avatica.remote.Service$FetchRequest.accept(Service.java:1370)
   at org.apache.calcite.avatica.remote.Service$FetchRequest.accept(Service.java:1337)
   at org.apache.calcite.avatica.remote.AbstractHandler.apply(AbstractHandler.java:94)
   at org.apache.calcite.avatica.remote.JsonHandler.apply(JsonHandler.java:52)
   at org.apache.calcite.avatica.server.AvaticaJsonHandler.handle(AvaticaJsonHandler.java:133)
   at org.apache.druid.sql.avatica.DruidAvaticaHandler.handle(DruidAvaticaHandler.java:59)
   at org.eclipse.jetty.server.handler.HandlerList.handle(HandlerList.java:59)
   at org.eclipse.jetty.server.handler.StatisticsHandler.handle(StatisticsHandler.java:173)
   at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:127)
   at org.eclipse.jetty.server.Server.handle(Server.java:501)
   at org.eclipse.jetty.server.HttpChannel.lambda$handle$1(HttpChannel.java:383)
   at org.eclipse.jetty.server.HttpChannel.dispatch(HttpChannel.java:556)
   at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:375)
   at org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:272)
   at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:311)
   at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:103)
   at org.eclipse.jetty.io.ChannelEndPoint$1.run(ChannelEndPoint.java:104)
   at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:336)
   at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:313)
   at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:171)
   at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKill.java:129)
   at org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:375)
   at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:806)
   at org.eclipse.jetty.util.thread.QueuedThreadPool$Runner.run(QueuedThreadPool.java:938)
   at java.lang.Thread.run(Thread.java:745)
   Suppressed: java.lang.RuntimeException: java.util.concurrent.ExecutionException: java.lang.IllegalStateException: DefaultQueryMetrics must not be modified from multiple threads. If it is needed to gather dimension or metric information from multiple threads or from an async thread, this information should explicitly be passed between threads (e. g. using Futures), or this DefaultQueryMetrics's ownerThread should be reassigned explicitly
   at org.apache.druid.sql.avatica.DruidStatement.close(DruidStatement.java:335)
   at org.apache.druid.sql.avatica.DruidStatement.nextFrame(DruidStatement.java:288)
   ... 27 more
   Caused by: java.util.concurrent.ExecutionException: java.lang.IllegalStateException: DefaultQueryMetrics must not be modified from multiple threads. If it is needed to gather dimension or metric information from multiple threads or from an async thread, this information should explicitly be passed between threads (e. g. using Futures), or this DefaultQueryMetrics's ownerThread should be reassigned explicitly
   at java.util.concurrent.FutureTask.report(FutureTask.java:122)
   at java.util.concurrent.FutureTask.get(FutureTask.java:192)
   at org.apache.druid.sql.avatica.DruidStatement.close(DruidStatement.java:317)
   ... 28 more
   Caused by: java.lang.IllegalStateException: DefaultQueryMetrics must not be modified from multiple threads. If it is needed to gather dimension or metric information from multiple threads or from an async thread, this information should explicitly be passed between threads (e. g. using Futures), or this DefaultQueryMetrics's ownerThread should be reassigned explicitly
   at org.apache.druid.query.DefaultQueryMetrics.checkModifiedFromOwnerThread(DefaultQueryMetrics.java:67)
   at org.apache.druid.query.DefaultQueryMetrics.reportMetric(DefaultQueryMetrics.java:354)
   at org.apache.druid.query.DefaultQueryMetrics.reportCpuTime(DefaultQueryMetrics.java:251)
   at org.apache.druid.query.CPUTimeMetricQueryRunner$1.after(CPUTimeMetricQueryRunner.java:92)
   at org.apache.druid.java.util.common.guava.WrappingYielder.close(WrappingYielder.java:98)
   at org.apache.druid.java.util.common.guava.WrappingYielder.close(WrappingYielder.java:82)
   at org.apache.druid.java.util.common.guava.ConcatSequence$2.close(ConcatSequence.java:145)
   at org.apache.druid.sql.avatica.DruidStatement.lambda$close$0(DruidStatement.java:313)
   at java.util.concurrent.FutureTask.run(FutureTask.java:266)
   at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
   at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
   ... 1 more
   
   


-- 
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:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@druid.apache.org
For additional commands, e-mail: commits-help@druid.apache.org