The JS Chat SDK has decided that in its API, subscribing to a room’s messages or presence messages should not trigger a channel attach operation (see decision record). In order to do this, it uses ably-js private API in order to, essentially, call RealtimeChannel#subscribe and RealtimePresence#subscribe in a way that does not trigger the RTL7c or RTP6c implicit attach.
For the Swift and Kotlin Chat SDKs, I would like us to instead be able to use an API that’s properly specified in this spec, even if marked as "experimental and for Ably-authored SDKs" only.
Suggested approach
Add some sort of subscribeWithoutImplicitAttach method to RealtimeChannel and RealtimePresence. Think of a way of not confusing users with this method.
Background
This arose in the context of https://github.com/ably-labs/ably-chat-swift/issues/18.
The JS Chat SDK has decided that in its API, subscribing to a room’s messages or presence messages should not trigger a channel attach operation (see decision record). In order to do this, it uses ably-js private API in order to, essentially, call
RealtimeChannel#subscribe
andRealtimePresence#subscribe
in a way that does not trigger the RTL7c or RTP6c implicit attach.For the Swift and Kotlin Chat SDKs, I would like us to instead be able to use an API that’s properly specified in this spec, even if marked as "experimental and for Ably-authored SDKs" only.
Suggested approach
Add some sort of
subscribeWithoutImplicitAttach
method toRealtimeChannel
andRealtimePresence
. Think of a way of not confusing users with this method.