-
Notifications
You must be signed in to change notification settings - Fork 40.8k
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
PropertiesLauncher does not respect classpath.idx when adding jars in BOOT-INF/lib to the classpath #41719
Comments
Yes, this is the expected behavior. Rather than an explanation of the status quo, it would be more interesting to understand why you care. In other words, why do you need to use |
We have two entry points within the application, so we need a way to specify the |
The documentation states that:
|
I know that This is not about I would be happy with any solution for the launching problem, it could be a parameter for |
I know that you know it ignores the index. My comment was explaining why the documentation's incorrect.
You can use
|
I know that you know the I know :-D Lol. Yep, clear.
I have tried that, but different order of libs causes bean initialization failures. The main app does not start because of that.
Yes, but I would have to transform 498 library entries from |
That won't be necessary once we've (hopefully) fixed this bug. |
@oldium This should be fixed now and available in snapshot releases. If you have the ability to test with a snapshot and give feedback, we'd appreciate it. Note that we decided to only apply this fix to the new loader, not to the classic loader. |
Perfect, thanks. This should simplify our startup script to use single loader for both application entry points. |
This is about
spring-boot-loader
module andorg.springframework.boot.loader.launch
package and is currently in themaster
Git branch.The
JarLauncher
is written in a way that it can be used on the unpacked JARs (used in a layered Docker images) easily, because it reads the existingBOOT-INF/classpath.idx
and thus respects the order of libraries. ThePropertiesLauncher
does not read theclasspath.idx
nor have an option to specify it, so the expected order of libraries is not respected. There is a possibility to read the index by script and put it into theloader.path
system property, but that would be large to specify it via the command line, so this brings another complication (although solvable). Conclusion is that thePropertiesLauncher
cannot be used easily on the unpacked JARs - on the layered images.The text was updated successfully, but these errors were encountered: