sillygod / cdp-cache

a caddy 2 proxy cache plugin
MIT License
120 stars 18 forks source link

cache type in_memory high usage memory #70

Open hieutm1 opened 1 year ago

hieutm1 commented 1 year ago

image memory high usage and auto kill service , please help. { "admin": { "listen": "0.0.0.0:7777" }, "apps": { "http": { "servers": { "server_0": { "listen": [ ":80" ], "routes": [ { "handle": [ {"config": { "cache_buckets_num": 512, "cache_key_template": "{http.request.method} {http.request.host}{http.request.uri.path}?{http.request.uri.query}", "cache_max_memory_size": 1073741824, "default_max_age": 300000000000, "lock_timeout": 300000000000, "match_methods": [ "GET", "HEAD" ], "rule_matcher_raws": [ { "Data": { "path": "/" }, "Type": "path" }, { "Data": { "header": "Content-Type", "value": [ "image/jpg", "image/png", "video/f4m", "video/mp2ts", "video/mp4", "video/x-m4v", "audio/x-m4a", "audio/mpeg" ] }, "Type": "header" } ], "status_header": "X-Cache-Status", "type": "in_memory", "path": "/tmp/caddy/" }, "handler": "http_cache" }, { "handler": "subroute", "routes": [ { "handle": [ { "handler": "headers", "response": { "deferred": true, "set": { "Cache-Control": [ "max-age=0" ] } } }, { "handler": "reverse_proxy", "headers": { "request": { "set": { "Host": [ "{http.reverse_proxy.upstream.host}" ] } } }, "transport": { "protocol": "http" }, "upstreams": [ { "dial": "tcp/192.168.1.12:80" } ] } ], "match": [ { "path": [ "/" ] } ] } ] } ], "match": [ { "host": [ "example.com", "cdn.example.com" ] }, { "path": [ "/" ] } ] } ] } } } }, "logging": { "logs": { "default": { "exclude": [ "http.log.access.log0" ] }, "log0": { "include": [ "http.log.access.log0" ], "level": "info" } } } }

Forza-tng commented 6 months ago

Hi, I noticed the same issue. About 5GiB in excess.

adammakowskidev commented 6 months ago

It appears that development has been abandoned.