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 2020/09/11 02:35:51 UTC

[GitHub] [druid] qianxinxu opened a new issue #10380: Druid 0.13.0 NPE problem

qianxinxu opened a new issue #10380:
URL: https://github.com/apache/druid/issues/10380


   There is a issue at MiddleManager node.
   My druid cluster verison is 0.13.0
   
   2020-09-10T22:32:04,280 INFO [DeliveryDiagnosisLog-incremental-persist] org.apache.druid.java.util.common.io.smoosh.FileSmoosher - Created smoosh file [/home/work/app/druid/logs/persistent/task/index_realtime_DeliveryDiagnosisLog_2020-09-11T06:00:00.000+08:00_1_0/work/persist/DeliveryDiagnosisLog/2020-09-10T22:00:00.000Z_2020-09-10T23:00:00.000Z/294/00000.smoosh] of size [2995891] bytes.
   2020-09-10T22:32:05,142 ERROR [task-runner-0-priority-0] org.apache.druid.indexing.common.task.RealtimeIndexTask - Exception aborted realtime processing[DeliveryDiagnosisLog]: {class=org.apache.druid.indexing.common.task.RealtimeIndexTask, exceptionType=class java.lang.NullPointerException, exceptionMessage=null}
   java.lang.NullPointerException
   	at org.apache.druid.segment.incremental.IncrementalIndex$IncrementalIndexRowComparator.compare(IncrementalIndex.java:1158) ~[druid-processing-0.13.0-incubating.jar:0.13.0-incubating]
   	at org.apache.druid.segment.incremental.IncrementalIndex$IncrementalIndexRowComparator.compare(IncrementalIndex.java:1145) ~[druid-processing-0.13.0-incubating.jar:0.13.0-incubating]
   	at java.util.concurrent.ConcurrentSkipListMap.cpr(ConcurrentSkipListMap.java:655) ~[?:1.8.0_202]
   	at java.util.concurrent.ConcurrentSkipListMap.doGet(ConcurrentSkipListMap.java:794) ~[?:1.8.0_202]
   	at java.util.concurrent.ConcurrentSkipListMap.get(ConcurrentSkipListMap.java:1546) ~[?:1.8.0_202]
   	at org.apache.druid.segment.incremental.IncrementalIndex$RollupFactsHolder.getPriorIndex(IncrementalIndex.java:1264) ~[druid-processing-0.13.0-incubating.jar:0.13.0-incubating]
   	at org.apache.druid.segment.incremental.OnheapIncrementalIndex.addToFacts(OnheapIncrementalIndex.java:157) ~[druid-processing-0.13.0-incubating.jar:0.13.0-incubating]
   	at org.apache.druid.segment.incremental.IncrementalIndex.add(IncrementalIndex.java:610) ~[druid-processing-0.13.0-incubating.jar:0.13.0-incubating]
   	at org.apache.druid.segment.realtime.plumber.Sink.add(Sink.java:181) ~[druid-server-0.13.0-incubating.jar:0.13.0-incubating]
   	at org.apache.druid.segment.realtime.plumber.RealtimePlumber.add(RealtimePlumber.java:224) ~[druid-server-0.13.0-incubating.jar:0.13.0-incubating]
   	at org.apache.druid.segment.realtime.plumber.Plumbers.addNextRow(Plumbers.java:72) ~[druid-server-0.13.0-incubating.jar:0.13.0-incubating]
   	at org.apache.druid.indexing.common.task.RealtimeIndexTask.run(RealtimeIndexTask.java:401) [druid-indexing-service-0.13.0-incubating.jar:0.13.0-incubating]
   	at org.apache.druid.indexing.overlord.SingleTaskBackgroundRunner$SingleTaskBackgroundRunnerCallable.call(SingleTaskBackgroundRunner.java:421) [druid-indexing-service-0.13.0-incubating.jar:0.13.0-incubating]
   	at org.apache.druid.indexing.overlord.SingleTaskBackgroundRunner$SingleTaskBackgroundRunnerCallable.call(SingleTaskBackgroundRunner.java:393) [druid-indexing-service-0.13.0-incubating.jar:0.13.0-incubating]
   	at java.util.concurrent.FutureTask.run(FutureTask.java:266) [?:1.8.0_202]
   	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_202]
   	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_202]
   	at java.lang.Thread.run(Thread.java:748) [?:1.8.0_202]
   2020-09-10T22:32:05,147 INFO [task-runner-0-priority-0] org.apache.druid.server.coordination.CuratorDataSegmentServerAnnouncer - Unannouncing self[DruidServerMetadata{name='c3-miui-ad-alg31.bj:8100', hostAndPort='c3-miui-ad-alg31.bj:8100', hostAndTlsPort='null', maxSize=0, tier='_default_tier', type=realtime, priority=0}] at [/druid/miuiad/production/prod/announcements/c3-miui-ad-alg31.bj:8100]
   2020-09-10T22:32:05,147 INFO [task-runner-0-priority-0] org.apache.druid.curator.announcement.Announcer - unannouncing [/druid/miuiad/production/prod/announcements/c3-miui-ad-alg31.bj:8100]
   2020-09-10T22:32:05,160 INFO [task-runner-0-priority-0] org.apache.druid.curator.discovery.CuratorDruidNodeAnnouncer - Unannouncing [DiscoveryDruidNode{druidNode=DruidNode{serviceName='druid/miuiad/production/prod/middlemanager', host='c3-miui-ad-alg31.bj', port=-1, plaintextPort=8100, enablePlaintextPort=true, tlsPort=-1, enableTlsPort=false}, nodeType='peon', services={dataNodeService=DataNodeService{tier='_default_tier', maxSize=0, type=realtime, priority=0}, lookupNodeService=LookupNodeService{lookupTier='__default'}}}].
   2020-09-10T22:32:05,160 INFO [task-runner-0-priority-0] org.apache.druid.curator.announcement.Announcer - unannouncing [/druid/miuiad/production/prod/internal-discovery/peon/c3-miui-ad-alg31.bj:8100]
   2020-09-10T22:32:05,163 INFO [task-runner-0-priority-0] org.apache.druid.curator.discovery.CuratorDruidNodeAnnouncer - Unannounced [DiscoveryDruidNode{druidNode=DruidNode{serviceName='druid/miuiad/production/prod/middlemanager', host='c3-miui-ad-alg31.bj', port=-1, plaintextPort=8100, enablePlaintextPort=true, tlsPort=-1, enableTlsPort=false}, nodeType='peon', services={dataNodeService=DataNodeService{tier='_default_tier', maxSize=0, type=realtime, priority=0}, lookupNodeService=LookupNodeService{lookupTier='__default'}}}].
   2020-09-10T22:32:05,163 ERROR [task-runner-0-priority-0] org.apache.druid.indexing.overlord.SingleTaskBackgroundRunner - Exception while running task[AbstractTask{id='index_realtime_DeliveryDiagnosisLog_2020-09-11T06:00:00.000+08:00_1_0', groupId='index_realtime_DeliveryDiagnosisLog', taskResource=TaskResource{availabilityGroup='DeliveryDiagnosisLog-22-0001', requiredCapacity=1}, dataSource='DeliveryDiagnosisLog', context={}}]
   java.lang.NullPointerException
   	at org.apache.druid.segment.incremental.IncrementalIndex$IncrementalIndexRowComparator.compare(IncrementalIndex.java:1158) ~[druid-processing-0.13.0-incubating.jar:0.13.0-incubating]
   	at org.apache.druid.segment.incremental.IncrementalIndex$IncrementalIndexRowComparator.compare(IncrementalIndex.java:1145) ~[druid-processing-0.13.0-incubating.jar:0.13.0-incubating]
   	at java.util.concurrent.ConcurrentSkipListMap.cpr(ConcurrentSkipListMap.java:655) ~[?:1.8.0_202]
   	at java.util.concurrent.ConcurrentSkipListMap.doGet(ConcurrentSkipListMap.java:794) ~[?:1.8.0_202]
   	at java.util.concurrent.ConcurrentSkipListMap.get(ConcurrentSkipListMap.java:1546) ~[?:1.8.0_202]
   	at org.apache.druid.segment.incremental.IncrementalIndex$RollupFactsHolder.getPriorIndex(IncrementalIndex.java:1264) ~[druid-processing-0.13.0-incubating.jar:0.13.0-incubating]
   	at org.apache.druid.segment.incremental.OnheapIncrementalIndex.addToFacts(OnheapIncrementalIndex.java:157) ~[druid-processing-0.13.0-incubating.jar:0.13.0-incubating]
   	at org.apache.druid.segment.incremental.IncrementalIndex.add(IncrementalIndex.java:610) ~[druid-processing-0.13.0-incubating.jar:0.13.0-incubating]
   	at org.apache.druid.segment.realtime.plumber.Sink.add(Sink.java:181) ~[druid-server-0.13.0-incubating.jar:0.13.0-incubating]
   	at org.apache.druid.segment.realtime.plumber.RealtimePlumber.add(RealtimePlumber.java:224) ~[druid-server-0.13.0-incubating.jar:0.13.0-incubating]
   	at org.apache.druid.segment.realtime.plumber.Plumbers.addNextRow(Plumbers.java:72) ~[druid-server-0.13.0-incubating.jar:0.13.0-incubating]
   	at org.apache.druid.indexing.common.task.RealtimeIndexTask.run(RealtimeIndexTask.java:401) ~[druid-indexing-service-0.13.0-incubating.jar:0.13.0-incubating]
   	at org.apache.druid.indexing.overlord.SingleTaskBackgroundRunner$SingleTaskBackgroundRunnerCallable.call(SingleTaskBackgroundRunner.java:421) [druid-indexing-service-0.13.0-incubating.jar:0.13.0-incubating]
   	at org.apache.druid.indexing.overlord.SingleTaskBackgroundRunner$SingleTaskBackgroundRunnerCallable.call(SingleTaskBackgroundRunner.java:393) [druid-indexing-service-0.13.0-incubating.jar:0.13.0-incubating]
   	at java.util.concurrent.FutureTask.run(FutureTask.java:266) [?:1.8.0_202]
   	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_202]
   	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_202]
   	at java.lang.Thread.run(Thread.java:748) [?:1.8.0_202]
   2020-09-10T22:32:05,163 INFO [task-runner-0-priority-0] org.apache.druid.indexing.overlord.TaskRunnerUtils - Task [index_realtime_DeliveryDiagnosisLog_2020-09-11T06:00:00.000+08:00_1_0] status changed to [FAILED].
   2020-09-10T22:32:05,166 INFO [task-runner-0-priority-0] org.apache.druid.indexing.worker.executor.ExecutorLifecycle - Task completed with status: {
     "id" : "index_realtime_DeliveryDiagnosisLog_2020-09-11T06:00:00.000+08:00_1_0",
     "status" : "FAILED",
     "duration" : 1529229,
     "errorMsg" : "java.lang.NullPointerException"
   }
   
   If I don't upgrade verison, how can I fix this bug?
   Thanks a lot!
   
   
   


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


[GitHub] [druid] tianzhipeng-git commented on issue #10380: Druid 0.13.0 NPE problem

Posted by GitBox <gi...@apache.org>.
tianzhipeng-git commented on issue #10380:
URL: https://github.com/apache/druid/issues/10380#issuecomment-693140391


   It's really strange, because I think it is impossible to generate NPE at  [`IncrementalIndex.java:1145->IncrementalIndex.java:1158`](https://github.com/apache/druid/blob/b924f717ee34d7aa48ad50c00eeae8ed84ec960f/processing/src/main/java/org/apache/druid/segment/incremental/IncrementalIndex.java#L1158) of 0.13.0-incubating:
   ```
       public int compare(IncrementalIndexRow lhs, IncrementalIndexRow rhs)
       {
   1158:      int retVal = Longs.compare(lhs.timestamp, rhs.timestamp);
   1159:      int numComparisons = Math.min(lhs.dims.length, rhs.dims.length);
   ```
   (lhs and rhs comes from ConcurrentSkipListMap, which are both not null, and lhs.timestamp is long type)
   
   But line 1159 can generate NPE, maybe the source code messed. (IncrementalIndex.java:1145 is strage too, it looks right if add 1 to 1146 and 1159)
   So in line 1159, the row's dims maybe null,  can you make sure that *all rows in your data have dims values*, without null row?
   
   ----
   In Chinese: 这个报错非常奇怪, 我觉得IncrementalIndex.java:1158不可能产生空指针异常, 代码见上.
   IncrementalIndexRow lhs和rhs都是从ConcurrentSkipListMap中取出来的, 都不可能为空, 且lhs.timestamp是原始long类型也不会报空指针.
   但是我发现1159行其实是可能空指针的, 可能是源码串行了. (IncrementalIndex.java:1145这一行也奇怪, 如果两个行号都加1就看起来都正常了)
   所以如果是1159报空指针, 那么说明lhs或rhs的dims数组是空的, 所以可能是你数据中, 有的数据行, 没有维度列的值? 


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


[GitHub] [druid] qianxinxu commented on issue #10380: Druid 0.13.0 NPE problem

Posted by GitBox <gi...@apache.org>.
qianxinxu commented on issue #10380:
URL: https://github.com/apache/druid/issues/10380#issuecomment-695927387


   > Opps, dims array can not be null too. i cannot do anything with this
   
   
   thanks


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


[GitHub] [druid] licl2014 commented on issue #10380: Druid 0.13.0 NPE problem

Posted by GitBox <gi...@apache.org>.
licl2014 commented on issue #10380:
URL: https://github.com/apache/druid/issues/10380#issuecomment-768103735


   I have the same problem


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


[GitHub] [druid] qianxinxu commented on issue #10380: Druid 0.13.0 NPE problem

Posted by GitBox <gi...@apache.org>.
qianxinxu commented on issue #10380:
URL: https://github.com/apache/druid/issues/10380#issuecomment-695927387


   > Opps, dims array can not be null too. i cannot do anything with this
   
   
   thanks


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


[GitHub] [druid] tianzhipeng-git commented on issue #10380: Druid 0.13.0 NPE problem

Posted by GitBox <gi...@apache.org>.
tianzhipeng-git commented on issue #10380:
URL: https://github.com/apache/druid/issues/10380#issuecomment-693296065


   Opps, dims array can not be null too. i cannot do anything with this


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


[GitHub] [druid] licl2014 commented on issue #10380: Druid 0.13.0 NPE problem

Posted by GitBox <gi...@apache.org>.
licl2014 commented on issue #10380:
URL: https://github.com/apache/druid/issues/10380#issuecomment-770665230


   0.12.3 @a2l007 


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


[GitHub] [druid] a2l007 commented on issue #10380: Druid 0.13.0 NPE problem

Posted by GitBox <gi...@apache.org>.
a2l007 commented on issue #10380:
URL: https://github.com/apache/druid/issues/10380#issuecomment-768337114


   @qianxinxu Are you still seeing this? 
   @licl2014 What version of druid are you encountering this error in?


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