Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update Java #481

Closed
robotdan opened this issue Feb 17, 2020 · 5 comments
Closed

Update Java #481

robotdan opened this issue Feb 17, 2020 · 5 comments
Assignees
Labels
architecture Feedback on designed behavior
Milestone

Comments

@robotdan
Copy link
Member

Upgrade Java from JRE8

Details

FusionAuth is currently using Oracle JRE8.

Oracle has moved away from the Oracle Binary License (BCL) which is the license had been operating under - to a license with even a more restrictive terms.

Oracle essentially has cut off all uses of Java in projects such s FusionAuth unless you purchase a license from Oracle. We have attempted to pursue a license with Oracle in the past, and the license costs are cost prohibitive - essentially being a percentage of our revenue.

For this and other reasons the next upgrade for FusionAuth will be to OpenJDK 12 or 13. We hope to make this transition in Q1 or Q2 of 2020.

BCL : https://www.oracle.com/downloads/licenses/binary-code-license.html
OTNL : https://www.oracle.com/downloads/licenses/javase-license1.html

Additional Context

From Oracle:
https://www.oracle.com/java/technologies/javase-jdk8-downloads.html

Important Oracle JDK License Update
The Oracle JDK License has changed for releases starting April 16, 2019.

The new Oracle Technology Network License Agreement for Oracle Java SE is substantially different from prior Oracle JDK licenses. The new license permits certain uses, such as personal use and development use, at no cost -- but other uses authorized under prior Oracle JDK licenses may no longer be available. Please review the terms carefully before downloading and using this product. An FAQ is available here.

Commercial license and support is available with a low cost Java SE Subscription.

Oracle also provides the latest OpenJDK release under the open source GPL License at jdk.java.net.

Original Description

Original title: Update JRE to 8u191

Original description:
Please upgrade the JRE to 8u191 so that we can use +UseContainerSupport for cgroup awareness.

Additional benefits will be that we will be able to (subject to enhancements) specify FUSIONAUTH_MEMORY as a percentage of RAM available instead of a static value (using +XX:MaxRAMPercentage). This has huge advantages i.t.o config management when running in the cloud and compute resources scale vertically.

Right now, we need to pre-touch the JVM heap but this causes an OOM error because the JVM is not respecting cgroup limits.

Original request FusionAuth/fusionauth-containers#30

@robotdan robotdan added the architecture Feedback on designed behavior label Feb 17, 2020
@robotdan
Copy link
Member Author

robotdan commented Feb 20, 2020

I spoke with Oracle and confirmed we can upgraded to JRE 8u202 and still be under the BCL, so as a stop gap we may be able to update to this version in the near term. The goal will still be to update to OpenJDK >= 13 soon.

Some free binary options:
https://adoptopenjdk.net/?variant=openjdk13&jvmVariant=hotspot
https://www.azul.com/products/zulu-community/

@robotdan
Copy link
Member Author

robotdan commented Mar 4, 2020

Guice dep for JDK 14
google/guice#1274

@robotdan robotdan added this to the 1.16.0 milestone Mar 23, 2020
@robotdan robotdan self-assigned this Mar 23, 2020
@ceefour
Copy link

ceefour commented Apr 17, 2020

@robotdan I would suggest (Adopt)OpenJDK 11 instead of 12/13/14 due to LTS status of 11 (security updates until 2024):

https://adoptopenjdk.net/support.html

@robotdan
Copy link
Member Author

We'll be releasing with JDK 14, the plan is to upgrade Java every 6-12 months to say within a supported window.

@ceefour
Copy link

ceefour commented Apr 18, 2020

@robotdan OK that makes sense. Are you sure intermediate versions not too quick? I worry that the overhead for keeping up with the JDK may take resources from more important things.

And for people not using Docker, most will prefer running on an LTS Java version. Most are comfortable using JDK 11 (for now), but will be wary of using non-LTS version.

Also the underlying components/libraries usually only support LTS versions optimally, for example with Spring: https://github.com/spring-projects/spring-framework/wiki/Spring-Framework-Versions

We fully test and support Spring on Long-Term Support (LTS) releases of the JDK, i.e. currently JDK 8 and 11 (both with a lifetime until 2023) and expecting JDK 17 (to be released in late 2021). Additionally, there is support for intermediate releases such as JDK 9/10/12/13/14 and the upcoming JDK 15/16 on a best-effort basis, meaning that we accept bug reports and will try to address them as far as technically possible but won't provide any service level guarantees.

There's increased risk and effort when using intermediate releases.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
architecture Feedback on designed behavior
Projects
None yet
Development

No branches or pull requests

2 participants