4 ms·
Are JREs still a thing (they were removed from Oracle builds in JDK 9)? Those were mostly for applets or JWS. Nowadays no one keeps just one JRE in their lapto
by krzyk 5y ago
Are JREs still a thing (they were removed from Oracle builds in JDK 9)?
Those were mostly for applets or JWS.
Nowadays no one keeps just one JRE in their laptop/desktop and disk sizes are in TBs so no point in saving 100 MB and lacking development tools.
And in one targets containers or systems with small amount of disk jlink give more gains than JRE.
- DarkmSparks 5y agoIf you are distributing software based on java a 40mb jre in place of a 400mb jdk is surely preferred. You can build them yourself for each OS you target with jlink, or you can just grab the latest built and tested one from e.g. Bellsoft - but not Adoptium or Oracle. Java has been "breaking changes" between releases to make python blush for a few years now, 17 finally looks like a worthy migration from 8.
- krzyk 5y agoJRE is like 44MB, JDK is 190MB. Difference is not 400 MB. And you get jshell, javac all the nice tools that I missed when some wise guys in distro or corp decided JRE is enough.
- DarkmSparks 5y agonot when extracted they arent. And jlink wont help you get a jdk for 32bit arm
- krzyk 5y agoExtraced: 323M jdk 136M jre Still, not 400 MB difference. If you want jdk you don't use jlink.
- DarkmSparks 5y ago>Still, not 400 MB difference. didn't say it was? A java.base jre is about 40mb extracted jdks extract to about 400mb (depending on os/arch) A downloaded then extracted jdk will take over 500mb of disk space
- jamesfinlayson 5y agoOfficially at least it seems that there are no post Java 8 JREs (or maybe Java 11 - I don't remember exactly) which is a shame. I know I can do it myself but having a small off the shelf runtime sure was convenient.
- DarkmSparks 5y agothere is no "officially" anymore, java has gone open source with distributors kinda like linux distributions. adoptium isn't the best distribution if you want to run on more than win/lin/mac x86_64.
- cbm-vic-20 5y agoJREs have basically been replaced with building custom executables via jlink. It basically includes a barebones JVM with only the modules that you need. You no longer have to either distribute or ask your users to download a JRE that includes the kitchen sink, you instead use jlink to create a custom distribution that only includes the modules that your code actually uses. For example, if your application does not use Swing, jlink won't include it.