-
Notifications
You must be signed in to change notification settings - Fork 54
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ShutdownHook: NoClassDefFoundError #17
Comments
|
We also see this when trying to upgrade a Tycho 3 build to Tycho 4. Tycho uses JGit in the tycho-buildtimestamp-jgit provider (but I'm not certain whether the failure is that related to that specific usage). Regarding the bug as such: I'd suggest to hardcode the cleanup failed message here (or to have a try-catch around the localized logging, falling back to hardcoded logging on any exception). Since the VM is shutting down, the JGitText class may or may not be loaded anymore, and that might even depend on the current JVM version or implementation. |
@msohn can you fix, please? |
pushed fix for review https://eclipse.gerrithub.io/c/eclipse-jgit/jgit/+/1176056 |
Fix was merged as e6d83d6 |
We also see this when trying to upgrade a Tycho 3 build to Tycho 4 in Xtext. @msohn the fix was merged but can we consume the fixed version somehow? |
I tagged the 6.9.0.202403050737-r release and contributed it to the simrel build yesterday. |
Hello, Edit: Thanks I see it released now: https://mvnrepository.com/artifact/org.eclipse.jgit/org.eclipse.jgit/6.9.0.202403050737-r |
Yes, technically it's already deployed on Maven Central. We announce the release with Eclipse simultaneous release next Wednesday. |
Hi, after updating to JGit 6.9 to fix the mentioned error, we are now getting:
is it related? |
JGit uses slf4j API for logging, if you want to use logback as logging backend you need to ensure that its jars are on the classpath |
They are. Everything is working well until the JVM is shutting down. Isn't it the same analysis as the JGitText not found?
|
In our case, we are using JGit in an application that is using classloader isolation. So I guess the problem is that we are closing our classloader before the JGit ShutdownHook is executed. For the record, here is a similar discussion: classgraph/classgraph#376 |
Hi folks, would you be open for a change letting clients call the cleanup method themself instead of relying on a shutdown hook? |
Why is this task closed? We are still getting:
|
Seems to relate to my case. Error is:
|
Most likely related, but ours is on
|
I'd recommend to create a new issue if there is still something wrong in the latest version... |
Version
latest
Operating System
Linux/Unix, MacOS, Windows
Bug description
at the end of each platform build an error is logged
Actual behavior
exception
Expected behavior
no exception, load the text while classloader available or inline string "Cleanup during JVM shutdown failed"
Relevant log output
Other information
example: https://github.com/eclipse-platform/eclipse.platform.ui/actions/runs/7529302359/job/20493249204?pr=1505)
The text was updated successfully, but these errors were encountered: