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

[Cache] remove implicit dependency on symfony/filesystem #33922

Merged
merged 1 commit into from Oct 9, 2019

Conversation

@nicolas-grekas
Copy link
Member

commented Oct 9, 2019

Q A
Branch? 4.3
Bug fix? yes
New feature? no
Deprecations? no
Tickets -
License MIT
Doc PR -

/cc @andrerom for review

@nicolas-grekas nicolas-grekas force-pushed the nicolas-grekas:cache-no-fs branch from 86212fe to 85f27f2 Oct 9, 2019
@@ -137,11 +129,6 @@ protected function doInvalidate(array $tagIds): bool
return true;

This comment has been minimized.

Copy link
@nicolas-grekas

nicolas-grekas Oct 9, 2019

Author Member

doInvalidate leaks inodes by not clearing the directory of invalidated tags, but this cannot be fixed with the current storage layout. We'd need a file listing item files instead of symlinks, as suggested in #33924. /cc @andrerom makes sense?

This comment has been minimized.

Copy link
@andrerom

andrerom Oct 9, 2019

Contributor

File representing cache tag where you append cache keys?

Could do that, but then:

  • more work (with race) to clean up relationship when tags are removed from an item _(unless we continue to view that as eventually consistent)
  • can it hit file limits if it only appends and never cares if cache key is already there?
  • on invalidation probably need to rename like with redis to be able to iterate and clear without race possibilities

So can work, but might present its own set of challenges.
Would it be better than replacing symlinks with just simple files that contain the cache key as value?

This comment has been minimized.

Copy link
@nicolas-grekas

nicolas-grekas Oct 9, 2019

Author Member

(continued in #33924 (comment))

@stof
stof approved these changes Oct 9, 2019
nicolas-grekas added a commit that referenced this pull request Oct 9, 2019
…nicolas-grekas)

This PR was merged into the 4.3 branch.

Discussion
----------

[Cache] remove implicit dependency on symfony/filesystem

| Q             | A
| ------------- | ---
| Branch?       | 4.3
| Bug fix?      | yes
| New feature?  | no
| Deprecations? | no
| Tickets       | -
| License       | MIT
| Doc PR        | -

/cc @andrerom for review

Commits
-------

85f27f2 [Cache] remove implicit dependency on symfony/filesystem
@nicolas-grekas nicolas-grekas merged commit 85f27f2 into symfony:4.3 Oct 9, 2019
3 checks passed
3 checks passed
continuous-integration/appveyor/pr AppVeyor build succeeded
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
fabbot.io Your code looks good.
Details
@nicolas-grekas nicolas-grekas deleted the nicolas-grekas:cache-no-fs branch Oct 9, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
4 participants
You can’t perform that action at this time.