-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
Disable the image build server by default #2598
Comments
Sounds good to me |
I recommend |
Disabled by default sounds better to me. |
Yes please. We use |
I'm in favor for flipping the default and making the build server usecase experimental. |
Proposing this change since no-server is now [enabled by default](oracle/graal#2598), and I got a warning that this flag is being ignored during the build.
Proposing this change since [no-server](oracle/graal#2598) is now enabled by default, and I got a warning that this flag is being ignored during the build. For context, I got the warning when building on cloud shell with Graal 22.0.0.2-r17.
The native-image tool has a mode that leaves the Java HotSpot VM performing the image build alive after an image build. Subsequent image builds can reuse that VM, which is then already warmed up and therefore subsequent image builds are faster.
Currently, the build server is enabled by default, and can be disabled using the option
--no-server
. We propose to flip the default, so that enabling the server requires an opt-in using--experimental-build-server
.While the build server has its uses, it is unfortunately not production quality at this point. We encounter bugs regularly where static state, especially in the JDK, survives from one build to another, leading to strange and hard-to-debug build errors (or even worse, runtime errors of the generated image). For example, #2554 is such a bug that is currently open. Fixing all the issues in a principled manner requires a level of isolation of the JDK that the image generator currently cannot provide: ideally, each image would get its own non-initialized copy of the JDK.
Several frameworks that support Native Image (Spring, Quarkus, Micronaut) already disable the build server by default or encourage users to disable it.
Alternatives:
If anyone has comments or a preference, please comment on this issue.
The text was updated successfully, but these errors were encountered: