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

Have support for JDK 11 #5

Open
gunnarmorling opened this issue Dec 1, 2020 · 3 comments
Open

Have support for JDK 11 #5

gunnarmorling opened this issue Dec 1, 2020 · 3 comments

Comments

@gunnarmorling
Copy link
Member

By dumping to a recording file and parsing that, JDK 11 might be a sufficient basis for an alternative mode of operation.

@geoand
Copy link

geoand commented Dec 18, 2020

https://github.com/newrelic/newrelic-jfr-core does something similar in order to support JDK 11 (non-streaming use case)

@sebersole
Copy link

Hi Gunnar!

We just started producing JFR events in Hibernate and have been using JFRUnit for testing. But we still baseline on Java 11, so this limitation is not ideal for us.

I'd be willing to take a look at supporting Java 11. Any pointers on where to start in your code?

@gunnarmorling
Copy link
Member Author

gunnarmorling commented Oct 5, 2023

Hey @sebersole, long time, no see :)

We just started producing JFR events in Hibernate and have been using JFRUnit for testing.

Woot, how cool is that!

But we still baseline on Java 11, so this limitation is not ideal for us.

Gotcha. Have you considered requiring a newer LTS (17, 21) for your own build, while still emitting Java 11 compatible build artifacts? It's quite comfortably doable these days, so that would be my recommendation. Unless anything stops you from building on Java 17+.

I'd be willing to take a look at supporting Java 11. Any pointers on where to start in your code?

References to EventStream should be the main problem here. So you could try and build this code base with Java 11 (EventStream was added in 14) and see where compilation fails. The question then would be how to implement the same functionality without having access to the live JFR event stream which currently is used. One idea was to dump recordings to disk and then load the events from there. This should be a viable approach in general, but one challenge may be to make sure it doesn't make things significantly slower than with the current stream-based approach.

That said, all in all, my recommendation, as stated above, would be exploring whether you can move your build to Java 17 or newer. With Java 21 being released as another LTS just lust month, my appetite for supporting LTS-2 is starting to diminish somewhat.

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

No branches or pull requests

3 participants