What are best practices for working with jlink?

In this guide, we will explore best practices for working with jlink, a tool that packages Java applications into custom runtime images. Implementing these strategies will help you optimize performance, reduce size, and ensure compatibility.
best practices, jlink, Java applications, custom runtime images, optimization, performance
// Example of using jlink to create a custom runtime image jlink --module-path $JAVA_HOME/jmods:myapp/libs \ --add-modules my.module \ --output myAppImage \ --launcher myApp=my.module/com.example.Main \ --name MyApp \ --strip-debug \ --no-header-files \ --no-man-pages

best practices jlink Java applications custom runtime images optimization performance