MCPcopy Create free account
hub / github.com/coder/coder / New

Function New

enterprise/derpmesh/derpmesh.go:20–29  ·  view source on GitHub ↗

New constructs a new mesh for DERP servers.

(logger slog.Logger, server *derp.Server, tlsConfig *tls.Config)

Source from the content-addressed store, hash-verified

18
19// New constructs a new mesh for DERP servers.
20func New(logger slog.Logger, server *derp.Server, tlsConfig *tls.Config) *Mesh {
21 return &Mesh{
22 logger: logger,
23 server: server,
24 tlsConfig: tlsConfig,
25 ctx: context.Background(),
26 closed: make(chan struct{}),
27 active: make(map[string]context.CancelFunc),
28 }
29}
30
31type Mesh struct {
32 logger slog.Logger

Callers 3

NewFunction · 0.92
NewFunction · 0.92
TestDERPMeshFunction · 0.92

Calls

no outgoing calls

Tested by 1

TestDERPMeshFunction · 0.74