我有一个基于parsingapache访问日志的服务,所以我需要即使在消失时打开也要login。
不,我只是简单地告诉Varnish不要caching特定的url:
if (req.url ~ "(foo|bar)") return(pass); }
但是资源很重,应该caching。 当Varnish将caching副本返回给客户端时,是否有任何可能性在apache访问日志上logging请求?
为什么不在前面使用清漆logging器,并在清漆上添加清漆(如果是碰撞或错过的话)
https://www.varnish-cache.org/docs/trunk/reference/varnishncsa.html
看看下面的内容
%{X}x Extended variables. Supported variables are: Varnish:time_firstbyte Time to the first byte from the backend arrived Varnish:hitmiss Whether the request was a cache hit or miss. Pipe and pass are considered misses. Varnish:handling How the request was handled, whether it was a cache hit, miss, pass, pipe or error. VCL_Log:key Output value set by std.log("key:value") in VCL.
默认情况下,它会发送一切到标准输出,但你可以redirect它