Use (latest) Java point versions from Ubuntu packages, instead of hard-coding old fix versions from in

See Old java version in bionic for background.

The way you install (recent) JDKs from in by downloading from with fixed versions seems not so great, to me.

Why not just “apt-get install -y openjdk-11-jdk-headless” to get the package from Ubuntu?

This would make it much easier to get the latest, e.g. 11.0.7 instead of your fixed year old 11.0.2.

We hacked this in, but it seems weird to have to do that.

Related posting Java/JDK on Travis CI

I totally support the request to use only for the latest-and-greatest JDK – long-term distros should be handled by different tool.