[squid-users] New line in logformat

Moti Berger moberger at metanetworks.com
Sun Sep 5 09:39:28 UTC 2021


Is there a performance hit by using a logformat per metric? Let's say I
need 5-10 metrics.

On Thu, Sep 2, 2021 at 8:15 PM His Shadow <shadowpilot34 at gmail.com> wrote:

> I think it would be easier to just write a logfile daemon, than
> patching squid. The protocol is very easy.
> http://www.squid-cache.org/Doc/config/logfile_daemon/
> You'd just ignore everything but lines starting with L.
>
> чт, 2 сент. 2021 г. в 16:49, Amos Jeffries <squid3 at treenet.co.nz>:
> >
> > On 3/09/21 12:07 am, Moti Berger wrote:
> > > Hi
> > >
> > > I want to send metrics to statsd, so I tried doing the following:
> > >
> > >     logformat metrics_statsd
> > >
>  my_service_latency:%{my_service}adapt::sum_trs|ms\nicap_total:%icap::tt|ms
> > >
> > >     access_log tcp://1.2.3.4:8125 <http://1.2.3.4:8125>
> > >     logformat=metrics_statsd
> > >
> > >
> > > In statsd daemon I see only the first (it supports multiple metrics
> > > separated by \n -
> >
> > Ouch.  You may be able to work around this with a logformat for each
> > metric you want to send and a access_log line sending that metric.
> >
> > Otherwise you are looking at a patch for either Squid or the statsd
> daemon.
> >
> > I am happy to assist with a patch for Squid if you want to. Contact me
> > directly for rates etc.
> >
> > Amos
> > _______________________________________________
> > squid-users mailing list
> > squid-users at lists.squid-cache.org
> > http://lists.squid-cache.org/listinfo/squid-users
>
>
>
> --
> HisShadow
> _______________________________________________
> squid-users mailing list
> squid-users at lists.squid-cache.org
> http://lists.squid-cache.org/listinfo/squid-users
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.squid-cache.org/pipermail/squid-users/attachments/20210905/d8ed2026/attachment.htm>


More information about the squid-users mailing list