Skip to content

bridge-client: expose prompt transport-close lifecycle for dispatch-aware requests #4640

Description

@snowykr

@gajae-code/bridge-client 0.13.3 exposes onFrame, onReconnect, onReconnectFailed, send, request, and control, but no instance-scoped transport close/error subscription.

A consumer that must synchronously mark the post-send dispatch boundary cannot use control()/request() directly: those APIs correctly retire pending requests on socket closure but do not expose the send-boundary callback. Its only alternative is a raw send() + onFrame() request, which cannot settle when the socket closes after send and before response; it waits until timeout.

Please expose one of:

  1. an instance-scoped close/error subscription that settles for the active transport generation; or
  2. a dispatch-aware request/control API with beforeDispatch/onDispatch callbacks while preserving the released client's pending-request retirement behavior.

The callback must fire synchronously after the frame handoff, and all close/error/reconnect cleanup must remain generation-safe.

Downstream report: snowykr/openwebui-gjc-adapter#34

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions