RFR: 8329581: Java launcher no longer prints a stack trace
Sonia Zaldana Calles
szaldana at openjdk.org
Mon May 6 16:30:11 UTC 2024
On Mon, 6 May 2024 10:21:12 GMT, Jaikiran Pai <jpai at openjdk.org> wrote:
>> Hi @mlchung, thanks for the feedback! I’ve pushed the updates.
>>
>> Just a question about ```NULL_CHECK0```.
>>
>> ```NULL_CHECK0``` reports the error message and then the exception is described in ```CHECK_EXCEPTION_LEAVE```. This results in a stack trace that looks like this:
>>
>>
>> Error: A JNI error has occurred, please check your installation and try again
>> Exception in thread "main" java.lang.NoClassDefFoundError: DemoSonia$SomeDependency
>> at DemoSonia.<clinit>(DemoSonia.java:3)
>> Caused by: java.lang.ClassNotFoundException: DemoSonia$SomeDependency
>> at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:641)
>> at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:188)
>> at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:528)
>> ... 1 more
>>
>>
>>
>> The JNI error message didn’t previously get reported before the regression was introduced, so I just wanted to make sure we were okay with this.
>>
>> Looking forward to your comments!
>
> Hello @SoniaZaldana, I don't remember seeing the `java/lang/Thread/UncaughtExceptionsTest` fail before. It's failing in the current PR's GitHub actions job on several platforms. Could you take a look if it's related to the current changes?
Hi @jaikiran, the failures were related to my change. I forgot to check the invocation failed and only trigger ```CHECK_EXCEPTION_LEAVE``` then. I have pushed an update that should fix the issue. Let's see how GHA turns out this time.
Thanks!
-------------
PR Comment: https://git.openjdk.org/jdk/pull/18786#issuecomment-2096439688
More information about the core-libs-dev
mailing list