Files
netbird/client/embed
mlsmaycon 231054c172 [client] Honor the start context while the embedded client authenticates
Start took a start context but ran auth.NewAuth and Login on a context derived
from Background, so the timeout only began to apply once authentication had
already returned. Both calls retry, and a management endpoint that accepts
connections but never completes a stream gives them nothing of their own to
time out against, so a client could sit in startup indefinitely with the
caller's deadline ignored.

A process running many clients behind a bounded start concurrency loses more
than one client to this: the stalled starts hold every slot, and the rest never
launch at all. Observed with 50 clients against a rate-limiting endpoint, where
seven came up, ten held the slots, and the remaining thirty-three never
started.

Neither call outlives startup, so moving them onto startCtx changes nothing
about the running client's lifetime.
2026-09-04 04:04:56 +02:00
..
2025-02-20 13:22:03 +01:00