You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix: overhaul caching system — real stats, working toggles, config merge
Cache stats:
- CacheStats endpoint now queries real Squid metrics via docker exec
squidclient mgr:info (was returning hardcoded zeros with simulated: true)
- Parse hit rate, byte hit rate, storage size, objects cached, hits/misses
- Added cachemgr_passwd in squid.conf for squidclient access
- Cache clear now uses squid -k purge via Docker exec (was hitting
non-existent HTTP endpoint that always failed silently)
Config generation:
- custom_squid.conf no longer overrides the entire generated config —
it is auto-migrated to custom_squid_extra.conf and appended instead.
This was the root cause of all cache settings being ignored.
- Removed duplicate refresh_pattern block (was defined twice in heredoc)
Feature toggles now functional:
- aggressive_caching_enabled: adds override-expire refresh patterns for
static assets, packages, and media files
- cache_bypass_domains: writes Squid ACL file + cache deny rules from
comma-separated domain list in settings
- enable_offline_mode: enables Squid offline_mode + aggressive stale
serving when origin servers are unreachable
Backend:
- Added ExecContainer to Docker client (create exec + start + capture
stdout with Docker stream mux header stripping)
- Settings handler writes toggle files + cache_bypass_domains.txt
for all three new cache features
- Fixed default setting name: offline_mode_enabled → enable_offline_mode
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
0 commit comments