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

Roll back [the change that made LocalCache avoid synchronized](https://github.com/google/guava/commit/1512730820a99e329a475b7143b7295775ef26ba). #6972

Merged
1 commit merged into from Feb 7, 2024

Conversation

copybara-service[bot]
Copy link
Contributor

Roll back the change that made LocalCache avoid synchronized.

The LocalCache change led to false reports of recursion during refresh.

This CL keeps the new tests from the LocalCache change, which already would have passed before the CL. Ideally we would additionally include tests that demonstrate the refresh problem, but we'll need to see if the contributor can sign a CLA.

This rollback un-fixes #6845. Users of common.cache and virtual threads will likely have to wait until synchronized no longer pins threads. (And at that point, if not earlier, they should migrate to Caffeine :))

RELNOTES=cache: Fixed a bug that could cause false "recursive load" reports during refresh.

…12730).

The `LocalCache` change led to [false reports of recursion during refresh](#6851 (comment)).

This CL keeps the new tests from the `LocalCache` change, which already would have passed before the CL. Ideally we would additionally include [tests that demonstrate the refresh problem](#6851 (comment)), but we'll need to see if the contributor can sign a CLA.

This rollback un-fixes #6845. Users of `common.cache` and virtual threads will likely have to wait until `synchronized` no longer pins threads. (And at that point, if not earlier, they should migrate to [Caffeine](https://github.com/ben-manes/caffeine) :))

RELNOTES=`cache`: Fixed a bug that could cause [false "recursive load" reports during refresh](#6851 (comment)).
PiperOrigin-RevId: 605069776
@copybara-service copybara-service bot closed this pull request by merging all changes into master in 0e1aebf Feb 7, 2024
@copybara-service copybara-service bot deleted the test_605049501 branch February 7, 2024 20:50
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.

remove synchronized from LocalCache::get(key, loader) to allow for VirtualThread-friendly value-loading
1 participant