Open
Description
Problem description
The current design forces a call-status subscription (org.camaraproject.webrtc-events.v0.session-status
) to include sessionId
, meaning the client must create a new subscription for every call instance.
- Unknown before the fact – Whether the call is outgoing or incoming, the client does not know the
sessionId
until after it receives the POST response (outgoing) orsession-invitation
event (incoming). - Race window – Establishing the subscription after the ID is learned allows status events to be published before the new subscription is active, causing missed notifications.
- Unnecessary churn – Spawning and deleting subscriptions for every call adds load to both client and gateway with no functional benefit.
Expected behavior
- Make
sessionId
optional insubscriptionDetail
. - When
sessionId
is omitted, the subscription applies to all sessions associated with the suppliedregistrationId
, covering both outgoing and incoming calls from the first status event onward. - If a client still needs to scope to a single call, it may include
sessionId
; otherwise, the per-registration subscription is the recommended default to eliminate race conditions and event loss.