pollForBinding checks the timeout before each poll, but not while a polling request is still in flight.
If the request takes longer than timeoutMs, it can return after the deadline. It also catches permanent errors such as HTTP 401 and eventually reports a generic timeout.
Expected behavior:
timeoutMs should be a hard deadline.
- In-flight polling should be cancelled when the deadline expires.
- Retry backoff should not continue after the deadline.
- Non-retryable errors should be returned immediately.
pollForBindingchecks the timeout before each poll, but not while a polling request is still in flight.If the request takes longer than
timeoutMs, it can return after the deadline. It also catches permanent errors such as HTTP 401 and eventually reports a generic timeout.Expected behavior:
timeoutMsshould be a hard deadline.