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

Adds a Checkstyle validation to ensure that the Guava cache is not used. #3631

Merged
merged 1 commit into from
Nov 29, 2023

Conversation

dlvenable
Copy link
Member

@dlvenable dlvenable commented Nov 10, 2023

Description

With #3586 updating to the Caffeine cache, we may still end up with Guava's cache being used. This PR adds a Checkstyle violation to prevent importing the Guava cache.

It's not perfect. I found you can work-around it by qualifying the class:

com.google.common.cache.Cache cache

But, that is more likely to be noticed during a code review.

Issues Resolved

N/A

Check List

  • New functionality includes testing.
  • New functionality has a documentation issue. Please link to it in this PR.
    • New functionality has javadoc added
  • Commits are signed with a real name per the DCO

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

@dlvenable dlvenable merged commit b1bd3fc into opensearch-project:main Nov 29, 2023
@dlvenable dlvenable deleted the guava-cache-disallow branch February 20, 2024 15:54
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

Successfully merging this pull request may close these issues.

3 participants