-
Bug
-
Resolution: Done
-
Major
-
2.1.4.Final, 2.2.0.Beta1
-
None
-
False
-
None
-
False
-
-
When building with JDK20, the Cassandra 3 build fails with this error:
2023-04-10T11:53:44.6254608Z java.lang.ExceptionInInitializerError 2023-04-10T11:53:44.6254956Z at org.github.jamm.MemoryMeter.measure(MemoryMeter.java:178) 2023-04-10T11:53:44.6255375Z at org.apache.cassandra.utils.ObjectSizes.measure(ObjectSizes.java:163) 2023-04-10T11:53:44.6255808Z at org.apache.cassandra.utils.ObjectSizes.<clinit>(ObjectSizes.java:39) 2023-04-10T11:53:44.6256272Z at org.apache.cassandra.dht.Murmur3Partitioner.<clinit>(Murmur3Partitioner.java:46) 2023-04-10T11:53:44.6256656Z at java.base/java.lang.Class.forName0(Native Method) 2023-04-10T11:53:44.6256983Z at java.base/java.lang.Class.forName(Class.java:391) 2023-04-10T11:53:44.6257290Z at java.base/java.lang.Class.forName(Class.java:382) 2023-04-10T11:53:44.6257747Z at org.apache.cassandra.utils.FBUtilities.classForName(FBUtilities.java:556) 2023-04-10T11:53:44.6258240Z at org.apache.cassandra.utils.FBUtilities.instanceOrConstruct(FBUtilities.java:572) 2023-04-10T11:53:44.6258735Z at org.apache.cassandra.utils.FBUtilities.newPartitioner(FBUtilities.java:522) 2023-04-10T11:53:44.6259198Z at org.apache.cassandra.utils.FBUtilities.newPartitioner(FBUtilities.java:508) 2023-04-10T11:53:44.6259707Z at org.apache.cassandra.config.DatabaseDescriptor.applyPartitioner(DatabaseDescriptor.java:1062) 2023-04-10T11:53:44.6260357Z at org.apache.cassandra.config.DatabaseDescriptor.toolInitialization(DatabaseDescriptor.java:195) 2023-04-10T11:53:44.6260945Z at org.apache.cassandra.config.DatabaseDescriptor.toolInitialization(DatabaseDescriptor.java:162) 2023-04-10T11:53:44.6261518Z at io.debezium.connector.cassandra.CassandraConnectorTask$Cassandra3SchemaLoader.load(CassandraConnectorTask.java:28) 2023-04-10T11:53:44.6262123Z at io.debezium.connector.cassandra.CassandraConnectorContext.<init>(CassandraConnectorContext.java:49) 2023-04-10T11:53:44.6262826Z at io.debezium.connector.cassandra.EmbeddedCassandra3ConnectorTestBase.generateTaskContext(EmbeddedCassandra3ConnectorTestBase.java:26) 2023-04-10T11:53:44.6263608Z at io.debezium.connector.cassandra.CassandraConnectorTestBase.generateTaskContext(CassandraConnectorTestBase.java:81) 2023-04-10T11:53:44.6264256Z at io.debezium.connector.cassandra.AbstractCommitLogProcessorTest.setUp(AbstractCommitLogProcessorTest.java:41) 2023-04-10T11:53:44.6264868Z at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:104) 2023-04-10T11:53:44.6265332Z at java.base/java.lang.reflect.Method.invoke(Method.java:578) 2023-04-10T11:53:44.6265741Z at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:59) 2023-04-10T11:53:44.6266207Z at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12) 2023-04-10T11:53:44.6266714Z at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:56) 2023-04-10T11:53:44.6267217Z at org.junit.internal.runners.statements.RunBefores.invokeMethod(RunBefores.java:33) 2023-04-10T11:53:44.6267709Z at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:24) 2023-04-10T11:53:44.6268178Z at org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:27) 2023-04-10T11:53:44.6268612Z at org.junit.runners.ParentRunner$3.evaluate(ParentRunner.java:306) 2023-04-10T11:53:44.6269043Z at org.junit.runners.BlockJUnit4ClassRunner$1.evaluate(BlockJUnit4ClassRunner.java:100) 2023-04-10T11:53:44.6269463Z at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:366) 2023-04-10T11:53:44.6269903Z at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:103) 2023-04-10T11:53:44.6270384Z at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:63) 2023-04-10T11:53:44.6270805Z at org.junit.runners.ParentRunner$4.run(ParentRunner.java:331) 2023-04-10T11:53:44.6271169Z at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:79) 2023-04-10T11:53:44.6271624Z at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:329) 2023-04-10T11:53:44.6272148Z at org.junit.runners.ParentRunner.access$100(ParentRunner.java:66) 2023-04-10T11:53:44.6272518Z at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:293) 2023-04-10T11:53:44.6272958Z at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:26) 2023-04-10T11:53:44.6273444Z at org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:27) 2023-04-10T11:53:44.6274017Z at org.testcontainers.containers.FailureDetectingExternalResource$1.evaluate(FailureDetectingExternalResource.java:30) 2023-04-10T11:53:44.6274492Z at org.junit.rules.RunRules.evaluate(RunRules.java:20) 2023-04-10T11:53:44.6274861Z at org.junit.runners.ParentRunner$3.evaluate(ParentRunner.java:306) 2023-04-10T11:53:44.6275236Z at org.junit.runners.ParentRunner.run(ParentRunner.java:413) 2023-04-10T11:53:44.6275708Z at org.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:377) 2023-04-10T11:53:44.6276226Z at org.apache.maven.surefire.junit4.JUnit4Provider.executeWithRerun(JUnit4Provider.java:284) 2023-04-10T11:53:44.6371792Z at org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:248) 2023-04-10T11:53:44.6372559Z at org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:167) 2023-04-10T11:53:44.6373203Z at org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:456) 2023-04-10T11:53:44.6374010Z at org.apache.maven.surefire.booter.ForkedBooter.execute(ForkedBooter.java:169) 2023-04-10T11:53:44.6374601Z at org.apache.maven.surefire.booter.ForkedBooter.run(ForkedBooter.java:595) 2023-04-10T11:53:44.6375427Z at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:581) 2023-04-10T11:53:44.6376400Z Caused by: java.lang.StringIndexOutOfBoundsException: Range [0, -1) out of bounds for length 10 2023-04-10T11:53:44.6376977Z at java.base/jdk.internal.util.Preconditions$1.apply(Preconditions.java:55) 2023-04-10T11:53:44.6377396Z at java.base/jdk.internal.util.Preconditions$1.apply(Preconditions.java:52) 2023-04-10T11:53:44.6377907Z at java.base/jdk.internal.util.Preconditions$4.apply(Preconditions.java:213) 2023-04-10T11:53:44.6378311Z at java.base/jdk.internal.util.Preconditions$4.apply(Preconditions.java:210) 2023-04-10T11:53:44.6378858Z at java.base/jdk.internal.util.Preconditions.outOfBounds(Preconditions.java:98) 2023-04-10T11:53:44.6379459Z at java.base/jdk.internal.util.Preconditions.outOfBoundsCheckFromToIndex(Preconditions.java:112) 2023-04-10T11:53:44.6380096Z at java.base/jdk.internal.util.Preconditions.checkFromToIndex(Preconditions.java:349) 2023-04-10T11:53:44.6381101Z at java.base/java.lang.String.checkBoundsBeginEnd(String.java:4608) 2023-04-10T11:53:44.6381582Z at java.base/java.lang.String.substring(String.java:2720) 2023-04-10T11:53:44.6401544Z at org.github.jamm.MemoryLayoutSpecification.getEffectiveMemoryLayoutSpecification(MemoryLayoutSpecification.java:190) 2023-04-10T11:53:44.6402445Z at org.github.jamm.MemoryLayoutSpecification.<clinit>(MemoryLayoutSpecification.java:31) 2023-04-10T11:53:44.6402943Z ... 51 more
This is because the cassandra-all dependency bundles JAMM 0.3.1 which does not support Java versions that have no dots in their names, such as JDK 20, and therefore the build fails.
Solution, bump JAMM dependency to 0.3.3.
- links to
-
RHEA-2023:120698 Red Hat build of Debezium 2.3.4 release