Repository navigation
[Docs] Explain the cost of FileSessionStore GC and how to run it out of band - #595
Merged
chr-hertel merged 3 commits intoOct 14, 2026
Merged
Conversation
chr-hertel
requested review from
CodeWithKyrian,
Nyholm and
soyuka
as code owners
October 13, 2026 23:33
Contributor
There was a problem hiding this comment.
🟢 Approval recommended
The documentation accurately reflects the implementation and provides a valid configuration example.
0 open findings
What changed in this PR
Documents the performance cost of file-session garbage collection and how to move it outside request handling.
Changes:
- Explains
FileSessionStore::gc()directory-scanning cost. - Adds an out-of-band cron example and PSR-16 alternative.
| File | Description |
|---|---|
src/Server/Session/FileSessionStore.php |
Documents GC scaling behavior. |
docs/run/sessions.md |
Adds external GC setup guidance. |
🧠 Review effort: Balanced
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
…g file locking in FileSessionStore' Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

FileSessionStore::gc()scans the whole session directory, inline on ~1% of requests, so busy servers pay for it on random requests.docs/run/sessions.mdgc()from cron insteadPsr16SessionStore, where the cache expires sessions itselfFixes chr-hertel#75
🤖 Generated with Claude Code