You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When compiled with java 17-level bytecode, tests in the presto-main module fail due to the asm dependency in drift not supporting java 17-compatible class files. Since we will eventually move to 21, we should just upgrade to the latest.
Sample failure trace
# Created at 2024-11-07T18:27:20.017
org.testng.TestNGException:
An error occurred while instantiating class com.facebook.presto.operator.TestOperatorInfoUnionSerde: null
at org.testng.internal.objects.SimpleObjectDispenser.createInstance(SimpleObjectDispenser.java:99)
at org.testng.internal.objects.SimpleObjectDispenser.dispense(SimpleObjectDispenser.java:40)
at org.testng.internal.objects.GuiceBasedObjectDispenser.dispense(GuiceBasedObjectDispenser.java:28)
at org.testng.internal.ClassImpl.getDefaultInstance(ClassImpl.java:106)
at org.testng.internal.ClassImpl.getInstances(ClassImpl.java:136)
at org.testng.TestClass.getInstances(TestClass.java:129)
at org.testng.TestClass.initTestClassesAndInstances(TestClass.java:109)
at org.testng.TestClass.init(TestClass.java:101)
at org.testng.TestClass.<init>(TestClass.java:66)
at org.testng.TestRunner.initMethods(TestRunner.java:465)
at org.testng.TestRunner.init(TestRunner.java:333)
at org.testng.TestRunner.init(TestRunner.java:286)
at org.testng.TestRunner.<init>(TestRunner.java:176)
at org.testng.SuiteRunner$DefaultTestRunnerFactory.newTestRunner(SuiteRunner.java:635)
at org.testng.SuiteRunner.init(SuiteRunner.java:221)
at org.testng.SuiteRunner.<init>(SuiteRunner.java:114)
at org.testng.TestNG.createSuiteRunner(TestNG.java:1342)
at org.testng.TestNG.createSuiteRunners(TestNG.java:1318)
at org.testng.TestNG.runSuitesLocally(TestNG.java:1160)
at org.testng.TestNG.runSuites(TestNG.java:1092)
at org.testng.TestNG.run(TestNG.java:1060)
at org.apache.maven.surefire.testng.TestNGExecutor.run(TestNGExecutor.java:155)
at org.apache.maven.surefire.testng.TestNGDirectoryTestSuite.executeMulti(TestNGDirectoryTestSuite.java:169)
at org.apache.maven.surefire.testng.TestNGDirectoryTestSuite.execute(TestNGDirectoryTestSuite.java:88)
at org.apache.maven.surefire.testng.TestNGProvider.invoke(TestNGProvider.java:137)
at org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:385)
at org.apache.maven.surefire.booter.ForkedBooter.execute(ForkedBooter.java:162)
at org.apache.maven.surefire.booter.ForkedBooter.run(ForkedBooter.java:507)
at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:495)
Caused by: java.lang.ExceptionInInitializerError
at java.base/jdk.internal.misc.Unsafe.ensureClassInitialized0(Native Method)
at java.base/jdk.internal.misc.Unsafe.ensureClassInitialized(Unsafe.java:1160)
at java.base/jdk.internal.reflect.MethodHandleAccessorFactory.ensureClassInitialized(MethodHandleAccessorFactory.java:300)
at java.base/jdk.internal.reflect.MethodHandleAccessorFactory.newConstructorAccessor(MethodHandleAccessorFactory.java:103)
at java.base/jdk.internal.reflect.ReflectionFactory.newConstructorAccessor(ReflectionFactory.java:200)
at java.base/java.lang.reflect.Constructor.acquireConstructorAccessor(Constructor.java:549)
at java.base/java.lang.reflect.Constructor.newInstanceWithCaller(Constructor.java:499)
at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:486)
at org.testng.internal.objects.InstanceCreator.newInstance(InstanceCreator.java:38)
at org.testng.ITestObjectFactory.newInstance(ITestObjectFactory.java:18)
at org.testng.internal.objects.SimpleObjectDispenser.instantiateUsingDefaultConstructor(SimpleObjectDispenser.java:178)
at org.testng.internal.objects.SimpleObjectDispenser.createInstance(SimpleObjectDispenser.java:87)
... 28 more
Caused by: com.google.common.util.concurrent.UncheckedExecutionException: com.google.common.util.concurrent.UncheckedExecutionException: com.google.common.util.concurrent.UncheckedExecutionException: com.google.common.util.concurrent.UncheckedExecutionException: java.lang.IllegalArgumentException: Unsupported class file major version 65
at com.google.common.cache.LocalCache$Segment.get(LocalCache.java:2086)
at com.google.common.cache.LocalCache.get(LocalCache.java:4012)
at com.google.common.cache.LocalCache.getOrLoad(LocalCache.java:4035)
at com.google.common.cache.LocalCache$LocalLoadingCache.get(LocalCache.java:5011)
at com.facebook.drift.codec.ThriftCodecManager.getCodec(ThriftCodecManager.java:232)
at com.facebook.drift.codec.ThriftCodecManager.getCodec(ThriftCodecManager.java:209)
at com.facebook.presto.operator.TestOperatorInfoUnionSerde.<clinit>(TestOperatorInfoUnionSerde.java:53)
... 40 more
Caused by: com.google.common.util.concurrent.UncheckedExecutionException: com.google.common.util.concurrent.UncheckedExecutionException: com.google.common.util.concurrent.UncheckedExecutionException: java.lang.IllegalArgumentException: Unsupported class file major version 65
at com.google.common.cache.LocalCache$Segment.get(LocalCache.java:2086)
at com.google.common.cache.LocalCache.get(LocalCache.java:4012)
at com.google.common.cache.LocalCache.getOrLoad(LocalCache.java:4035)
at com.google.common.cache.LocalCache$LocalLoadingCache.get(LocalCache.java:5011)
at com.facebook.drift.codec.ThriftCodecManager.getCodec(ThriftCodecManager.java:232)
at com.facebook.drift.codec.internal.compiler.ThriftCodecByteCodeGenerator.declareCodecFields(ThriftCodecByteCodeGenerator.java:239)
at com.facebook.drift.codec.internal.compiler.ThriftCodecByteCodeGenerator.<init>(ThriftCodecByteCodeGenerator.java:165)
at com.facebook.drift.codec.internal.compiler.CompilerThriftCodecFactory.generateThriftTypeCodec(CompilerThriftCodecFactory.java:61)
at com.facebook.drift.codec.ThriftCodecManager$1.load(ThriftCodecManager.java:143)
at com.facebook.drift.codec.ThriftCodecManager$1.load(ThriftCodecManager.java:127)
at com.google.common.cache.LocalCache$LoadingValueReference.loadFuture(LocalCache.java:3571)
at com.google.common.cache.LocalCache$Segment.loadSync(LocalCache.java:2313)
at com.google.common.cache.LocalCache$Segment.lockedGetOrLoad(LocalCache.java:2190)
at com.google.common.cache.LocalCache$Segment.get(LocalCache.java:2080)
... 46 more
Caused by: com.google.common.util.concurrent.UncheckedExecutionException: com.google.common.util.concurrent.UncheckedExecutionException: java.lang.IllegalArgumentException: Unsupported class file major version 65
at com.google.common.cache.LocalCache$Segment.get(LocalCache.java:2086)
at com.google.common.cache.LocalCache.get(LocalCache.java:4012)
at com.google.common.cache.LocalCache.getOrLoad(LocalCache.java:4035)
at com.google.common.cache.LocalCache$LocalLoadingCache.get(LocalCache.java:5011)
at com.facebook.drift.codec.ThriftCodecManager.getCodec(ThriftCodecManager.java:232)
at com.facebook.drift.codec.internal.compiler.ThriftCodecByteCodeGenerator.declareCodecFields(ThriftCodecByteCodeGenerator.java:239)
at com.facebook.drift.codec.internal.compiler.ThriftCodecByteCodeGenerator.<init>(ThriftCodecByteCodeGenerator.java:165)
at com.facebook.drift.codec.internal.compiler.CompilerThriftCodecFactory.generateThriftTypeCodec(CompilerThriftCodecFactory.java:61)
at com.facebook.drift.codec.ThriftCodecManager$1.load(ThriftCodecManager.java:143)
at com.facebook.drift.codec.ThriftCodecManager$1.load(ThriftCodecManager.java:127)
at com.google.common.cache.LocalCache$LoadingValueReference.loadFuture(LocalCache.java:3571)
at com.google.common.cache.LocalCache$Segment.loadSync(LocalCache.java:2313)
at com.google.common.cache.LocalCache$Segment.lockedGetOrLoad(LocalCache.java:2190)
at com.google.common.cache.LocalCache$Segment.get(LocalCache.java:2080)
... 59 more
Caused by: com.google.common.util.concurrent.UncheckedExecutionException: java.lang.IllegalArgumentException: Unsupported class file major version 65
at com.google.common.cache.LocalCache$Segment.get(LocalCache.java:2086)
at com.google.common.cache.LocalCache.get(LocalCache.java:4012)
at com.google.common.cache.LocalCache.getOrLoad(LocalCache.java:4035)
at com.google.common.cache.LocalCache$LocalLoadingCache.get(LocalCache.java:5011)
at com.facebook.drift.codec.ThriftCodecManager.getCodec(ThriftCodecManager.java:232)
at com.facebook.drift.codec.ThriftCodecManager.getElementCodec(ThriftCodecManager.java:195)
at com.facebook.drift.codec.ThriftCodecManager$1.load(ThriftCodecManager.java:149)
at com.facebook.drift.codec.ThriftCodecManager$1.load(ThriftCodecManager.java:127)
at com.google.common.cache.LocalCache$LoadingValueReference.loadFuture(LocalCache.java:3571)
at com.google.common.cache.LocalCache$Segment.loadSync(LocalCache.java:2313)
at com.google.common.cache.LocalCache$Segment.lockedGetOrLoad(LocalCache.java:2190)
at com.google.common.cache.LocalCache$Segment.get(LocalCache.java:2080)
... 72 more
Caused by: java.lang.IllegalArgumentException: Unsupported class file major version 65
at org.objectweb.asm.ClassReader.<init>(ClassReader.java:199)
at org.objectweb.asm.ClassReader.<init>(ClassReader.java:180)
at org.objectweb.asm.ClassReader.<init>(ClassReader.java:166)
at org.objectweb.asm.ClassReader.<init>(ClassReader.java:287)
at com.facebook.airlift.bytecode.ClassInfoLoader.readClassInfoQuick(ClassInfoLoader.java:100)
at com.facebook.airlift.bytecode.ClassInfoLoader.loadClassInfo(ClassInfoLoader.java:76)
at com.facebook.airlift.bytecode.SmartClassWriter.getCommonSuperClass(SmartClassWriter.java:34)
at org.objectweb.asm.SymbolTable.addMergedType(SymbolTable.java:1202)
at org.objectweb.asm.Frame.merge(Frame.java:1299)
at org.objectweb.asm.Frame.merge(Frame.java:1244)
at org.objectweb.asm.MethodWriter.computeAllFrames(MethodWriter.java:1610)
at org.objectweb.asm.MethodWriter.visitMaxs(MethodWriter.java:1546)
at com.facebook.airlift.bytecode.MethodDefinition.visit(MethodDefinition.java:257)
at com.facebook.airlift.bytecode.MethodDefinition.visit(MethodDefinition.java:211)
at com.facebook.airlift.bytecode.ClassDefinition.visit(ClassDefinition.java:167)
at com.facebook.airlift.bytecode.ClassGenerator.defineClasses(ClassGenerator.java:130)
at com.facebook.airlift.bytecode.ClassGenerator.defineClass(ClassGenerator.java:117)
at com.facebook.drift.codec.internal.compiler.ThriftCodecByteCodeGenerator.<init>(ThriftCodecByteCodeGenerator.java:198)
at com.facebook.drift.codec.internal.compiler.CompilerThriftCodecFactory.generateThriftTypeCodec(CompilerThriftCodecFactory.java:61)
at com.facebook.drift.codec.ThriftCodecManager$1.load(ThriftCodecManager.java:143)
at com.facebook.drift.codec.ThriftCodecManager$1.load(ThriftCodecManager.java:127)
at com.google.common.cache.LocalCache$LoadingValueReference.loadFuture(LocalCache.java:3571)
at com.google.common.cache.LocalCache$Segment.loadSync(LocalCache.java:2313)
at com.google.common.cache.LocalCache$Segment.lockedGetOrLoad(LocalCache.java:2190)
at com.google.common.cache.LocalCache$Segment.get(LocalCache.java:2080)
... 83 more
The text was updated successfully, but these errors were encountered:
ZacBlanco
changed the title
upgrade asm to support java classes compiled with version <=21
upgrade asm to support java classes compiled with version 21+
Nov 8, 2024
When compiled with java 17-level bytecode, tests in the
presto-main
module fail due to the asm dependency in drift not supporting java 17-compatible class files. Since we will eventually move to 21, we should just upgrade to the latest.Sample failure trace
The text was updated successfully, but these errors were encountered: