Skip to main content

Resilience: hbf-webchat

Error handling and retry patterns for this service. Platform-wide patterns: docs/architecture/resilience.md

HTTP Retry

  • Library: botframework-webchat (Microsoft Bot Framework) with native retry handling
  • Attempts: SDK default (not explicitly configured)
  • Backoff: SDK default
  • On failure: Delegated entirely to Bot Framework SDK internals

Queue Retry

Not applicable. Frontend widget, no queue consumers.

Timeouts

CallTimeoutConfigured in
Message send (sendTimeout)20000ms (20s)Bot Framework SDK config
Attachment send (sendTimeoutForAttachments)120000ms (2 min)Bot Framework SDK config
Other HTTP callsNone (no explicit timeout)N/A

Circuit Breakers

None implemented.

Fallback Strategy

Failure scenarioBehaviourUser impact
Token expired at startupisTokenExpiredAtStartUp flag set, triggers reconnection flowBrief delay while token refreshes
Direct Line connection lostisDirectLineConnectionFulfilled tracks stateChat becomes unresponsive until reconnection

Known Gaps

  • No explicit retry logic in widget code; entirely dependent on Bot Framework SDK internal retry behaviour
  • No custom error recovery beyond token refresh on startup
  • Timeout configured only on message/attachment sends, not on other HTTP calls the widget may make
  • No user-facing error state or reconnection UI when Direct Line connection drops