mirror of
https://github.com/ossrs/srs.git
synced 2025-03-09 15:49:59 +00:00
RTC: Stat the WebRTC clients bandwidth. v5.0.50
This commit is contained in:
parent
d7c2d5ab01
commit
4fe90d4885
5 changed files with 49 additions and 2 deletions
|
@ -643,6 +643,10 @@ srs_error_t SrsRtcServer::on_timer(srs_utime_t interval)
|
|||
// Update stat if session is alive.
|
||||
if (session->is_alive()) {
|
||||
nn_rtc_conns++;
|
||||
|
||||
ISrsKbpsDelta* conn = dynamic_cast<ISrsKbpsDelta*>(session);
|
||||
SrsStatistic::instance()->kbps_add_delta(session->get_id().c_str(), conn);
|
||||
|
||||
continue;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue