chore: fix cleanup follow-ups and regression coverage#4380
Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #4380 +/- ##
==========================================
+ Coverage 91.33% 91.35% +0.01%
==========================================
Files 132 132
Lines 13105 13145 +40
==========================================
+ Hits 11970 12008 +38
- Misses 716 717 +1
- Partials 419 420 +1
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
@copilot Two checks are red on this PR: Please fix the linter findings, then add test coverage for the changed paths so the patch-coverage gate passes. Since this is a cleanup with no intended behavior change, the new tests should mostly assert that behavior is unchanged. |
Addressed in |
|
@copilot Detailed annotations after checking this PR against the findings listed in #4364: 1. Lint root cause (
2. Completeness vs #4364. Finding #4 (SSE heartbeat) is correctly skipped, it already selects on the done channel. But finding #1 (cache heap unbounded growth, 3. Finding #6 ( 4. Finding #8 ( 5. Coverage ( |
Addressed in |
|
@copilot The Benchmark and Test jobs both fail to build, because the proxy test was not updated to match the new client type. You changed the proxy client to
Update |
Addressed in
Addressed in |
Description
Tightens a focused set of cleanup follow-ups from the earlier pass while keeping the behavior-neutral scope requested in review. The remaining changes address bounded memory growth in the cookie jar, faster shutdown of background work, a lock-free proxy client read path, and the lint/test follow-ups needed to keep the branch green.
The previously proposed
BaseURL()allocation tweak and multipart file buffer size reduction were dropped after review, and the cache heap growth finding is deferred rather than addressed in this pull request.Changes introduced
Runtime cleanup and shutdown behavior
TimeDoneinstead of sleeping uninterruptibly.Close()no longer risks blocking on repeated calls.atomic.Pointerfor lock-free access.Memory growth controls
Allocation and state follow-ups
Route()fallback reuses zero-length backing arrays without exposing shared mutable state.Focused regression coverage and lint follow-up
//nolintdirectives in the touched test/support files and removed the leftover revive marker so lint stays green without changing intended behavior.Deferred item
Type of change
Please delete options that are not relevant.
Checklist
Before you submit your pull request, please make sure you meet these requirements:
/docs/directory for Fiber's documentation.Commit formatting
Please use emojis in commit messages for an easy way to identify the purpose or intention of a commit. Check out the emoji cheatsheet here: CONTRIBUTING.md