Skip to content

Exception when running the dump-segment tool #13645

@erankor

Description

@erankor

Affected Version

25.0.0

Description

Hi,

I'm trying to run the 'dump-segment' tool, and getting the following exception -

# java --add-opens java.base/java.lang=ALL-UNNAMED -classpath "/opt/apache-druid-25.0.0/lib/*"  -Ddruid.extensions.loadList="[]" org.apache.druid.cli.Main tools dump-segment -d /tmp/segment/
Exception in thread "main" java.lang.IllegalAccessError: class org.apache.datasketches.memory.internal.AccessByteBuffer (in unnamed module @0x1dde4cb2) cannot access class sun.nio.ch.DirectBuffer (in module java.base) because module java.base does not export sun.nio.ch to unnamed module @0x1dde4cb2
        at org.apache.datasketches.memory.internal.AccessByteBuffer.<init>(AccessByteBuffer.java:66)
        at org.apache.datasketches.memory.internal.BaseWritableMemoryImpl.wrapByteBuffer(BaseWritableMemoryImpl.java:112)
        at org.apache.datasketches.memory.Memory.wrap(Memory.java:66)
        at org.apache.druid.segment.data.LongsLongEncodingReader.<init>(LongsLongEncodingReader.java:33)
        at org.apache.druid.segment.data.CompressionFactory$LongEncodingFormat$3.getReader(CompressionFactory.java:186)
        at org.apache.druid.segment.data.CompressionFactory.getLongSupplier(CompressionFactory.java:315)
        at org.apache.druid.segment.data.CompressedColumnarLongsSupplier.fromByteBuffer(CompressedColumnarLongsSupplier.java:117)
        at org.apache.druid.segment.serde.LongNumericColumnPartSerde.lambda$getDeserializer$0(LongNumericColumnPartSerde.java:100)
        at org.apache.druid.segment.column.ColumnDescriptor.read(ColumnDescriptor.java:111)
        at org.apache.druid.segment.IndexIO$V9IndexLoader.deserializeColumn(IndexIO.java:796)
        at org.apache.druid.segment.IndexIO$V9IndexLoader.registerColumnHolder(IndexIO.java:771)
        at org.apache.druid.segment.IndexIO$V9IndexLoader.load(IndexIO.java:632)
        at org.apache.druid.segment.IndexIO.loadIndex(IndexIO.java:202)
        at org.apache.druid.segment.IndexIO.loadIndex(IndexIO.java:192)
        at org.apache.druid.cli.DumpSegment.run(DumpSegment.java:199)
        at org.apache.druid.cli.Main.main(Main.java:112)

My Java version is -

# java --version
openjdk 17.0.5 2022-10-18
OpenJDK Runtime Environment (build 17.0.5+8-Ubuntu-2ubuntu120.04)
OpenJDK 64-Bit Server VM (build 17.0.5+8-Ubuntu-2ubuntu120.04, mixed mode, sharing)

(even though I tried also Java 19 on Windows, and got the same exception...)

Am I missing something? Or maybe some change broke the dump-segment tool?

Thanks!

Eran

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions