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

JDK8 doesn't supported? #514

Closed
catap opened this issue Mar 12, 2021 · 5 comments
Closed

JDK8 doesn't supported? #514

catap opened this issue Mar 12, 2021 · 5 comments

Comments

@catap
Copy link

catap commented Mar 12, 2021

Hey,

I've tried to use the last release (3.0.0) with JDK8 and can't build it with error:

[ERROR]   bad class file: /Users/catap/.m2/repository/com/github/ben-manes/caffeine/caffeine/3.0.0/caffeine-3.0.0.jar(com/github/benmanes/caffeine/cache/Cache.class)
[ERROR]     class file has wrong version 55.0, should be 52.0
[ERROR]     Please remove or make sure it appears in the correct subdirectory of the classpath.

Is JDK8 supported? I haven't find any clear statement about it.

@ben-manes
Copy link
Owner

Hi @catap,

Java 8 is supported by 2.x versions which will still be actively maintained. Java 11 is required for 3.x in order to use VarHandles instead of requiring Unsafe. This is briefly mentioned in the release notes for v3.

@catap
Copy link
Author

catap commented Mar 12, 2021

@ben-manes sorry, I've missed that.

@catap catap closed this as completed Mar 12, 2021
@ben-manes
Copy link
Owner

No problem! I added more emphasis in the release notes, as I can certainly understand the concern.

@manju-v
Copy link

manju-v commented May 7, 2021

but the refresh related improvements which were done in 3.0.0 will not be available in 2.x versions right?

@ben-manes
Copy link
Owner

Correct. That was a large change to the feature which bordered on not being appropriate for a minor release. A major release would highlight that possibly incompatible changes were made which requires more diligence when upgrading.

See for example #537 (comment) where a deadlock occurs because the user took advantage of the prior implementation not being linearizable, where returning the refresh future would block as part of a batching enhancement. This has to be changed to fit the new implementation. While it is unfortunate to see this bite someone, the major version bump gave a stronger warning of a potential break so it comes as less of a surprise.

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