MCPcopy
hub / github.com/cloudflare/cloudflared / logConnected

Method logConnected

connection/observer.go:58–68  ·  view source on GitHub ↗
(connectionID uuid.UUID, connIndex uint8, location string, address net.IP, protocol Protocol)

Source from the content-addressed store, hash-verified

56}
57
58func (o *Observer) logConnected(connectionID uuid.UUID, connIndex uint8, location string, address net.IP, protocol Protocol) {
59 o.log.Info().
60 Int(management.EventTypeKey, int(management.Cloudflared)).
61 Str(LogFieldConnectionID, connectionID.String()).
62 Uint8(LogFieldConnIndex, connIndex).
63 Str(LogFieldLocation, location).
64 IPAddr(LogFieldIPAddress, address).
65 Str(LogFieldProtocol, protocol.String()).
66 Msg("Registered tunnel connection")
67 o.metrics.registerServerLocation(uint8ToString(connIndex), location)
68}
69
70func (o *Observer) sendRegisteringEvent(connIndex uint8) {
71 o.sendEvent(Event{Index: connIndex, EventType: RegisteringTunnel})

Callers 1

ServeControlStreamMethod · 0.80

Calls 4

IntMethod · 0.80
uint8ToStringFunction · 0.70
StringMethod · 0.65

Tested by

no test coverage detected