Live data from Hacker News

Which version of JDK should I use?

whichjdk.com

201–210 of 258 posts

Re: Which version of JDK should I use?

#201

These recommendations are pretty arbitrary and don't even attempt to scratch the surface of what is actually materially different between the JDKs. Don't use Corretto outside of Amazon... why? Don't use Dragonwell because... China bad? Use Red Hat OpenJDK if you're running on Red Hat servers, Microsoft OpenJDK if you're on Azure, SapMachine if you're on SAP, because... the name matches so that's nice? At least they'r…

> Use whatever vendor happens to be most convenient to install

Yes -- do what everyone else does.

> Generally go with JDK 11

Seconded.

User rococode is dead on correct here.

Re: Which version of JDK should I use?

#202
post #81

Earlier quoted context omitted.

Yes - .NET 5 and 6 both have runtimes and SDKs available for Mac and Linux. At least in my opinion, Linux is the preferred deployment platform for it now unless you have a specific (usually older) library that only works on Windows.

.NET 5 finally delivered Linux support but only eleven months ago, so I would test it some before betting the farm.

> .NET 5 finally delivered Linux support but only eleven months ago

The previous versions in this stream (.NET Core 2.1, .NET Core 3.0 and 3.1) also run fine on Linux. For web server / API server workloads, it's been stable for a lot longer than 11 months, and people do indeed "bet the farm" or "run the business" on it, quite happily.

Technically, this starts with .NET core 2.1 on 2018-05-30. The prior version, 2.0, released on 2017-08-14, wasn't _quite_ there yet although some people were happy with it for production use.

Re: Which version of JDK should I use?

#203

These recommendations are pretty arbitrary and don't even attempt to scratch the surface of what is actually materially different between the JDKs. Don't use Corretto outside of Amazon... why? Don't use Dragonwell because... China bad? Use Red Hat OpenJDK if you're running on Red Hat servers, Microsoft OpenJDK if you're on Azure, SapMachine if you're on SAP, because... the name matches so that's nice? At least they'r…

> the name matches so that's nice?

To me it sounds reasonable that Microsoft tests/optimizes their JDK better for Azure, and Amazon -- for AWS.

Re: Which version of JDK should I use?

#204
IMHO this mess will hurt Java on the medium-long run.

All of this is unnecessarily complicated and confusing, as a developer it really feels like they don't want me to use Java.

I have the feeling that, similarly to what happened with the Roman empire, greed, laziness and burocracy are going to drag everything down.

Re: Which version of JDK should I use?

#205
post #204

IMHO this mess will hurt Java on the medium-long run. All of this is unnecessarily complicated and confusing, as a developer it really feels like they don't want me to use Java. I have the feeling that, similarly to what happened with the Roman empire, greed, laziness and burocracy are going to drag everything down.

How is it a mess?

You have official Oracle JDK build.

You have official Oracle OpenJDK build.

You have plenty of alternative builds.

It's like kernel.org Linux, Debian Linux, Fedora Linux and so on. Does it hurt Linux? I don't think so.

All builds should be perfectly compatible between each other.

Simplest way is just use Oracle JDK 17. It's LTS, free and official.

Re: Which version of JDK should I use?

#206
post #204

IMHO this mess will hurt Java on the medium-long run. All of this is unnecessarily complicated and confusing, as a developer it really feels like they don't want me to use Java. I have the feeling that, similarly to what happened with the Roman empire, greed, laziness and burocracy are going to drag everything down.

How is it a mess? You have official Oracle JDK build. You have official Oracle OpenJDK build. You have plenty of alternative builds. It's like kernel.org Linux, Debian Linux, Fedora Linux and so on. Does it hurt Linux? I don't think so. All builds should be perfectly compatible between each other. Simplest way is just use Oracle JDK 17. It's LTS, free and official.

I largely agree, but would only say -- consider if your use-case needs LTS[1]. Not every use-case does.

[1] https://news.ycombinator.com/item?id=26478175

Re: Which version of JDK should I use?

#207
post #191
post #161

Earlier quoted context omitted.

Almost all distros ship at least openjdk-11, and many including Debian have openjdk-17 now.

Cool, but did they had 16? Or will they have 18? I use the newest Java version available.

In most environments it's better to use a LTS version

Re: Which version of JDK should I use?

#208
post #204

IMHO this mess will hurt Java on the medium-long run. All of this is unnecessarily complicated and confusing, as a developer it really feels like they don't want me to use Java. I have the feeling that, similarly to what happened with the Roman empire, greed, laziness and burocracy are going to drag everything down.

How is it a mess? You have official Oracle JDK build. You have official Oracle OpenJDK build. You have plenty of alternative builds. It's like kernel.org Linux, Debian Linux, Fedora Linux and so on. Does it hurt Linux? I don't think so. All builds should be perfectly compatible between each other. Simplest way is just use Oracle JDK 17. It's LTS, free and official.

It's a mess because for the average joe such as myself it's very confusing and foggy.

There's an Oracle jdk whose usage terms need to be deciphered using a lawyer to understand precisely when and how you can use it. So much that the average advice is to not use it. Like if they told you "hey, node.js is cool but don't use the one from those who maintain and develop the code". This would be a huge red flag for any other language than Java, which can leverage 30 years of sunk costs for companies that now will not switch lightly to something else.

The alternative builds are good, yet not official and they might introduce thin incompatibilities or different behaviors. They should not but this whole article suggests that they actually do.

The simple existence of articles like this one testifies that this is a mess for a lot of people.

Re: Which version of JDK should I use?

#209
post #111

Earlier quoted context omitted.

> When Oracle acquired Sun in 2010-11, Sun had not shipped a new release of Java in more than four years.[0] That's hardly a "stability" worth treasuring. Sun went several years without releasing a new major version, but that same page lists frequent minor updates. So yes, I would call that exactly a stability to treasure.

More like stagnation.

Java language development itself wasn't stagnating, as far as I understand only the release process was stuck on a licensing dispute. IBM and other members of the Java Community Process stonewalled every new feature in the hope that they could force Sun to certify Apache licensed Java implementations like Harmony.

Re: Which version of JDK should I use?

#210
post #192

Earlier quoted context omitted.

If 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.

JRE 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.

not when extracted they arent. And jlink wont help you get a jdk for 32bit arm
Post reply on HN