Skip to content
This repository has been archived by the owner on Oct 25, 2024. It is now read-only.

Cannot get single publication/subscription's statistics #523

Open
milanyummy opened this issue Nov 12, 2021 · 1 comment
Open

Cannot get single publication/subscription's statistics #523

milanyummy opened this issue Nov 12, 2021 · 1 comment

Comments

@milanyummy
Copy link

Hi everyone,
I am using OWT 5.0.x SDK and I know since 5.0, all publications and subscriptions for the same conference use the same PeerConnection. So when I use getStats( ) function of a single publication/subscription, I can get all the statistics of this PeerConnection, including all publications and subscriptions. I just want to know how to relate the statistics I get from getStats( ) to single publication/subscription.

Thank you.

@milanyummy milanyummy changed the title Cannot single publication/subscription's statistics Cannot get single publication/subscription's statistics Nov 12, 2021
@jianjunz
Copy link
Collaborator

Hi,

You may need to modify the SDK to get the RTCRtpTransceiver associated with a publication or a subscription.

this._publishTransceivers = new Map(); // internalId => { id, transceivers: [Transceiver] }
this._subscribeTransceivers = new Map(); // internalId => { id, transceivers: [Transceiver] }
But if you publish a stream with a RTCRtpTransceiver, which is a new feature added after 5.0, you can call getStats of its RTCRtpSender or RTCRtpReceiver.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants