js-bao-wss-client / ChannelSubscribeFailedEvent
Interface: ChannelSubscribeFailedEvent
A channel subscription the server refused when nothing was waiting on it.
Emitted over the channelSubscribeFailed event channel (client.on("channelSubscribeFailed", ...)). The case this exists for is RECONNECT: after the socket comes back the client presents each held grant again, and a grant that expired while the connection was down is refused with no pending call to reject. The registration for that channel — and only that channel — is dropped, and this is how an app hears about it, so it can ask its authorizing function for a fresh grant and subscribe again.
A refusal that answers a JsBaoClient.subscribeToChannel call is reported by rejecting that promise instead, so a failure is never announced twice. message is the server's uniform refusal: an expired, tampered, cross-app or cross-user grant are deliberately indistinguishable.
Properties
channel
channel:
string
message
message:
string