Presto: "size is negative" error

Created on 12 Aug 2019  路  2Comments  路  Source: prestodb/presto

SpatialIndexBuilderOperator is reporting a negative size in the finish method, from a build off of master (de65d64d15).

This ultimately delegates down to the RTree memory size, which https://github.com/prestodb/presto/pull/13079 would affect and hopefully fix.

cc @mbasmanova @aweisberg

java.lang.IllegalArgumentException: size is negative
    at io.airlift.units.Preconditions.checkArgument(Preconditions.java:26)
    at io.airlift.units.DataSize.<init>(DataSize.java:58)
    at io.airlift.units.DataSize.succinctDataSize(DataSize.java:48)
    at io.airlift.units.DataSize.succinctBytes(DataSize.java:43)
    at com.facebook.presto.memory.QueryContext.lambda$getAdditionalFailureInfo$2(QueryContext.java:357)
    at com.google.common.collect.CollectCollectors.lambda$toImmutableMap$1(CollectCollectors.java:61)
    at java.base/java.util.stream.ReduceOps$3ReducingSink.accept(ReduceOps.java:169)
    at java.base/java.util.stream.SliceOps$1$1.accept(SliceOps.java:199)
    at java.base/java.util.stream.SortedOps$SizedRefSortingSink.end(SortedOps.java:361)
    at java.base/java.util.stream.AbstractPipeline.copyIntoWithCancel(AbstractPipeline.java:503)
    at java.base/java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:488)
    at java.base/java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:474)
    at java.base/java.util.stream.ReduceOps$ReduceOp.evaluateSequential(ReduceOps.java:913)
    at java.base/java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)
    at java.base/java.util.stream.ReferencePipeline.collect(ReferencePipeline.java:578)
    at com.facebook.presto.memory.QueryContext.getAdditionalFailureInfo(QueryContext.java:357)
    at com.facebook.presto.memory.QueryContext.enforceUserMemoryLimit(QueryContext.java:329)
    at com.facebook.presto.memory.QueryContext.updateUserMemory(QueryContext.java:136)
    at com.facebook.presto.memory.QueryContext$QueryMemoryReservationHandler.reserveMemory(QueryContext.java:310)
    at com.facebook.presto.memory.context.RootAggregatedMemoryContext.updateBytes(RootAggregatedMemoryContext.java:37)
    at com.facebook.presto.memory.context.ChildAggregatedMemoryContext.updateBytes(ChildAggregatedMemoryContext.java:38)
    at com.facebook.presto.memory.context.ChildAggregatedMemoryContext.updateBytes(ChildAggregatedMemoryContext.java:38)
    at com.facebook.presto.memory.context.ChildAggregatedMemoryContext.updateBytes(ChildAggregatedMemoryContext.java:38)
    at com.facebook.presto.memory.context.ChildAggregatedMemoryContext.updateBytes(ChildAggregatedMemoryContext.java:38)
    at com.facebook.presto.memory.context.SimpleLocalMemoryContext.setBytes(SimpleLocalMemoryContext.java:66)
    at com.facebook.presto.operator.OperatorContext$InternalLocalMemoryContext.setBytes(OperatorContext.java:598)
    at com.facebook.presto.operator.SpatialIndexBuilderOperator.finish(SpatialIndexBuilderOperator.java:234)
    at com.facebook.presto.operator.Driver.processInternal(Driver.java:397)
    at com.facebook.presto.operator.Driver.lambda$processFor$8(Driver.java:283)
    at com.facebook.presto.operator.Driver.tryWithLock(Driver.java:675)
    at com.facebook.presto.operator.Driver.processFor(Driver.java:276)
    at com.facebook.presto.execution.SqlTaskExecution$DriverSplitRunner.processFor(SqlTaskExecution.java:1077)
    at com.facebook.presto.execution.executor.PrioritizedSplitRunner.process(PrioritizedSplitRunner.java:162)
    at com.facebook.presto.execution.executor.TaskExecutor$TaskRunner.run(TaskExecutor.java:483)
    at com.facebook.presto.$gen.Presto_0_225_SNAPSHOT_de65d64____20190812_181222_1.run(Unknown Source)
    at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1135)
    at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
    at java.base/java.lang.Thread.run(Thread.java:844)

Most helpful comment

I think this PR fixes this issue: https://github.com/prestodb/presto/pull/13120 /cc @kewang1024 @rongrong

All 2 comments

CC: @zhenxiao

I think this PR fixes this issue: https://github.com/prestodb/presto/pull/13120 /cc @kewang1024 @rongrong

Was this page helpful?
0 / 5 - 0 ratings