Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 3d8dad4ce9
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
Pull request overview
Fixes session-expiry resource leaks by ensuring expiring sessions that own resources are closed before removal from in-memory storage, with accompanying unit tests validating the new cleanup behavior.
Changes:
- Update
LocalStorage.DeleteExpired()to callClose()on sessions that implementio.Closerbefore deleting them. - Add unit tests covering
io.Closersessions, non-closer sessions, andClose()error handling.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| pkg/transport/session/storage_local.go | Adds io.Closer detection and Close() invocation during expired-session cleanup, with warning logs on close failure. |
| pkg/transport/session/storage_test.go | Introduces a closable mock session and adds test cases for closer/non-closer deletion and close-error behavior. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #4014 +/- ##
==========================================
- Coverage 68.60% 68.56% -0.05%
==========================================
Files 444 444
Lines 45184 45202 +18
==========================================
- Hits 31000 30993 -7
- Misses 11783 11812 +29
+ Partials 2401 2397 -4 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 2 out of 2 changed files in this pull request and generated 4 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Implements fix by calling Close() on sessions that implement io.Closer before deleting them from storage during cleanup. This prevents connection leaks when vMCP sessions with backend clients expire. Closes: #3871
Implements fix by calling Close() on sessions that implement io.Closer before deleting them from storage during cleanup. This prevents connection leaks when vMCP sessions with backend clients expire.
Closes: #3871