Skip to content

Commit ccd81ba

Browse files
committed
fix(realtime): tighten the token-retry comment
1 parent fe7e147 commit ccd81ba

1 file changed

Lines changed: 2 additions & 4 deletions

File tree

‎apps/sim/app/workspace/providers/socket-provider.tsx‎

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -455,10 +455,8 @@ export function SocketProvider({ children, user }: SocketProviderProps) {
455455
}
456456
if (!socketInstance.active || socketInstance.connected) return
457457

458-
/* Withholding `cb` would hold the open transport until the realtime
459-
server's 45 s connect timeout, and the Manager resets its backoff on
460-
every transport open, so it cannot pace this retry. End the attempt
461-
and reconnect on our own backoff, never before `Retry-After`. */
458+
// Withholding `cb` would park the transport until the server's 45 s connect
459+
// timeout, and the Manager resets its backoff on every open, so pace it here.
462460
tokenRetryAttemptsRef.current += 1
463461
const retryAfterMs =
464462
error instanceof SocketTokenUnavailableError ? error.retryAfterMs : null

0 commit comments

Comments
 (0)