MCPcopy Index your code
hub / github.com/coder/coder / streamStateCollector

Struct streamStateCollector

coderd/x/chatd/chatd.go:1349–1351  ·  view source on GitHub ↗

streamStateCollector exposes scrape-time gauges derived from p.chatStreams. Scrape cost is O(n) with a brief per-state mutex held for two len() reads; acceptable at typical scrape cadences.

Source from the content-addressed store, hash-verified

1347// p.chatStreams. Scrape cost is O(n) with a brief per-state mutex
1348// held for two len() reads; acceptable at typical scrape cadences.
1349type streamStateCollector struct {
1350 server *Server
1351}
1352
1353var (
1354 streamsActiveDesc = prometheus.NewDesc(

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected