tsnet: add support for clientmetrics.

Updates https://github.com/tailscale/tailscale/issues/1748

Signed-off-by: Denton Gentry <dgentry@tailscale.com>
pull/8920/head
Denton Gentry 1 year ago committed by Denton Gentry
parent c15997511d
commit f486041fd1

@ -51,6 +51,7 @@ import (
"tailscale.com/types/logger"
"tailscale.com/types/logid"
"tailscale.com/types/nettype"
"tailscale.com/util/clientmetric"
"tailscale.com/util/mak"
"tailscale.com/util/testenv"
"tailscale.com/wgengine"
@ -640,6 +641,7 @@ func (s *Server) startLogger(closePool *closeOnErrorPool) error {
return w
},
HTTPC: &http.Client{Transport: logpolicy.NewLogtailTransport(logtail.DefaultHost, s.netMon, s.logf)},
MetricsDelta: clientmetric.EncodeLogTailMetricsDelta,
}
s.logtail = logtail.NewLogger(c, s.logf)
closePool.addFunc(func() { s.logtail.Shutdown(context.Background()) })

Loading…
Cancel
Save