perf(cache): replace MarshalIndent with Marshal in local cache#164
perf(cache): replace MarshalIndent with Marshal in local cache#164SantiagoDePolonia merged 1 commit intomainfrom
Conversation
The local model cache file is never read by humans — only by the application on startup. MarshalIndent allocates extra buffer space for indentation, adding unnecessary GC pressure on every cache refresh cycle. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Pro Run ID: 📒 Files selected for processing (1)
📝 WalkthroughWalkthroughThe Changes
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~2 minutes Poem
🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Summary
json.MarshalIndentwithjson.Marshalin local model cacheSet()— the cache file is only read by the application, never by humansSaveToCache→MarshalIndentaccounted for ~7.8 MB of allocations across 500 requestsTest plan
TestLocalCachetests pass (round-trip Get/Set verified)🤖 Generated with Claude Code
Summary by CodeRabbit