I like jpackage but I think for the time being I will live with a little bigger disk and memory footprint and not bother spending the time working with jlink😂
@learnnewskill1857
26 күн бұрын
Hii, Thank you for creating a more informative video. I have one question regarding Custom JRE. Que: If we create a custom JRE with the help Jdeps and JLink. Can we create that custom JRE folder into docker image and when we create any spring boot project with Docker file, we directly pull that custom JRE from docker, Not pull any openJDK:21 and Not any other image only pull over custom JRE and start our spring boot application, it's possible or not?. Can you please create a video on that. Please 🙏
@pluschlorinds446
5 ай бұрын
8:14 I created a custom runtime with the command beblow, but it was 111MB (110MB lib directory only). did I do something wrong? jlink --output custom-java --add-modules java.base OS: Ubuntu 23.10 (x64) java 22 2024-03-19 Java(TM) SE Runtime Environment Oracle GraalVM 22+36.1 (build 22+36-jvmci-b02) Java HotSpot(TM) 64-Bit Server VM Oracle GraalVM 22+36.1 (build 22+36-jvmci-b02, mixed mode, sharing)
@quelvix
5 ай бұрын
I only tried it in 1 personal project and it was an absolute pain. If any of your dependencies doesn't support modules, you're doomed. And widely used dependencies like Apache Commons Codec are among these libraries. Never again.
@dmitrikonnov922
4 ай бұрын
As for me, building custom runtimes or native images entails so much overhead which moreover infilters the operation procedures, that it makes using java in greenfield cloud-native environment look more and more unattractive compared to other languages like Golang etc. Yes, the latter one and its libraries have not been as mature nor versatile as those for Java, but easy to write, build, deploy & operate, has a small memory footprint and starts fast.
@SourabhBhat
7 ай бұрын
For me, jlink (and jpackage) has been useful when sharing an application with someone who may not have proper JDK installed. Otherwise, if I am setting up the environment, it is more efficient to just use the jar/class-files using the already installed JDK.
@kevinnguyen163
7 ай бұрын
I think it makes more sense for production deployment where you might need to spin up hundred of microservices and those MB and startup time saved are important.
@kevinnguyen163
7 ай бұрын
Also, as you might've noticed, most JDK vendors stopped releasing JRE, only JDK is availalbe (except for Eclipse Temurin). For those with more concern on having JDK stuff in the system is more risky, it makes sense to build custom runtime image.
@sen7826
7 ай бұрын
I have a problem with jpackage because it does not really wrap the jar into an exe but rather the exe file actually just runs the jar file which you can actually manually find inside the installation folder.
@SourabhBhat
7 ай бұрын
@@sen7826To create a native executable you can use "native-image" from graalvm JDK. It works well for headless applications.
@ByronGoodman
7 ай бұрын
Once native-image becomes more mature, jlink will be pointless.
@DonaldOldingHebb658
7 ай бұрын
Очень информативно, спасибо!
@Agagh
6 ай бұрын
Native images are slowly killing jlink
@abduvohid8311
3 ай бұрын
Cool. We are looking forward to new updates
@jcbrites
7 ай бұрын
very informative. Thanks!
@GaffaStudios
7 ай бұрын
It would be interesting to see how to handle applications with non-modular third party libraries.
@TooOnwura
7 ай бұрын
Nice
@pmorah
7 ай бұрын
Great presentation. Thanks
@bartek38912051
7 ай бұрын
Maybe stupid question not related to this topic, but is memory leak issue possible in java?
@charonstyxferryman
7 ай бұрын
In the JVM, memory management is not manual (like e.g. C++), but done automatically by the JVM's GC (Garbage Collector), so no.
@cmyanmar13
5 ай бұрын
Yes: Running threads are not GC'd, so you must manage them manually.
Пікірлер: 26