Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Backport changes to congestion control from libwebrtc #922

Draft
wants to merge 81 commits into
base: v3
Choose a base branch
from

Conversation

sarumjanuch
Copy link
Contributor

This MR will track progress of sync libwebrtc congestion control in mediasoup to catchup with all the changes for the last 2 years, and most importantly- loss based estimator v2

@ibc
Copy link
Member

ibc commented Oct 10, 2022

Amazing. Just to clarify, this PR:

  • Updates libwebrtc code related to TCC and so on.
  • Adds new loss based estimator v2 but doesn't use it yet.

Is it correct?

@sarumjanuch
Copy link
Contributor Author

That is 100% correct. This is very WIP, but first commits that compiles. I will continue working on this.

@ibc
Copy link
Member

ibc commented Oct 10, 2022

Wondering if we should mark the PR as draft to avoid wrong expectations for other readers. Not critical at all.

@sarumjanuch
Copy link
Contributor Author

sarumjanuch commented Oct 10, 2022 via email

@jmillan jmillan marked this pull request as draft October 10, 2022 14:14
@jmillan
Copy link
Member

jmillan commented Oct 10, 2022

Converted to draft

@ibc ibc linked an issue Nov 4, 2022 that may be closed by this pull request
ibc added a commit that referenced this pull request Nov 4, 2022
- Fix calculation of feedback min_pending_time in goog_cc
  - Fixes #849
  - Commit in libwebrtc: https://webrtc.googlesource.com/src/+/d65dc979b17cdc7cd359aada59e5bce8a6f1b8ce%5E%21/
-
Fix signed-to-unsigned overflow in send_side_bandwidth_estimation.cc
  - Fixes #872
  - Issue in libwebrtc: https://bugs.chromium.org/p/webrtc/issues/detail?id=14272
  - Commit in libwebrtc: https://webrtc.googlesource.com/src/+/9804aa5f6ad26a45338d685da66497c3bbd88ca6%5E%21/

NOTE: Some changes are already present in ongoing PR #922 but it's not yet merged.
@ibc ibc mentioned this pull request Nov 4, 2022
@ibc ibc linked an issue Nov 4, 2022 that may be closed by this pull request
ibc added a commit that referenced this pull request Nov 4, 2022
- Fix calculation of feedback min_pending_time in goog_cc
  - Fixes #849
  - Commit in libwebrtc: https://webrtc.googlesource.com/src/+/d65dc979b17cdc7cd359aada59e5bce8a6f1b8ce%5E%21/
-
Fix signed-to-unsigned overflow in send_side_bandwidth_estimation.cc
  - Fixes #872
  - Issue in libwebrtc: https://bugs.chromium.org/p/webrtc/issues/detail?id=14272
  - Commit in libwebrtc: https://webrtc.googlesource.com/src/+/9804aa5f6ad26a45338d685da66497c3bbd88ca6%5E%21/

NOTE: Some changes are already present in ongoing PR #922 but it's not yet merged.
Eugene Voityuk and others added 16 commits November 14, 2022 16:51
# Conflicts:
#	worker/deps/libwebrtc/libwebrtc/modules/bitrate_controller/send_side_bandwidth_estimation.cc
…ave no traffic due to low reported estimated bitrate. Change min bitrate constant.
…ddenly have no traffic due to low reported estimated bitrate. Change min bitrate constant."

This reverts commit 676b92e.
…Pacer, and therfore we should allow bigger bursts.
…Pacer, and therfore we should allow bigger bursts.
…unable to recover. Fix instant loss calculation at high bitrates. Increase ObservationDurationLowerBound.
@umeshc
Copy link

umeshc commented Jan 11, 2023

Is there a timeline for when this PR can be merged into the mainline code? For the past 3 weeks, not had much activity, Is anything that I can be of any help with?

@sarumjanuch
Copy link
Contributor Author

@umeshc That is github showing wrong info, i was committing code yesterday, and will commit today. We are very actively testing everything to pick right params, don't worry, it will be merged as soon as we will be confident in stability and satisfied with overall results.

…ant loss. Extract rtx bitrate from available outgoing bitrate when distributing.
@sarumjanuch
Copy link
Contributor Author

As of right now, this is blocked by #989

piranna pushed a commit to dyte-in/mediasoup that referenced this pull request Feb 9, 2023
- Fix calculation of feedback min_pending_time in goog_cc
  - Fixes versatica#849
  - Commit in libwebrtc: https://webrtc.googlesource.com/src/+/d65dc979b17cdc7cd359aada59e5bce8a6f1b8ce%5E%21/
-
Fix signed-to-unsigned overflow in send_side_bandwidth_estimation.cc
  - Fixes versatica#872
  - Issue in libwebrtc: https://bugs.chromium.org/p/webrtc/issues/detail?id=14272
  - Commit in libwebrtc: https://webrtc.googlesource.com/src/+/9804aa5f6ad26a45338d685da66497c3bbd88ca6%5E%21/

NOTE: Some changes are already present in ongoing PR versatica#922 but it's not yet merged.
@ibc
Copy link
Member

ibc commented Mar 24, 2023

May want to see this #1031

@vpalmisano
Copy link
Contributor

Do you have any update/plan for this PR? Thanks!

@ibc
Copy link
Member

ibc commented Apr 25, 2023

Do you have any update/plan for this PR? Thanks!

We are in an offsite this week, let's come to this next week after Monday.

@ibc
Copy link
Member

ibc commented May 3, 2023

Do you have any update/plan for this PR? Thanks!

So current state is on hold. This PR indeee modernized libwebrtc but it also comes with too many custom changes due to libwebrtc assumptions and hardcoded values, making it harder to maintain if we merge it. So we need to discuss how to proceed with this. Will update as soon as there is news.

@ggarber
Copy link
Contributor

ggarber commented May 24, 2023

@sarumjanuch FYC Given how awesome (and risky) is this change I think it would be great if there is a simple doc / readme with this info:

  • What is the exact version that is being used in this PR (is the one from libwebrtc 8mo ago?) and what files have been upgraded vs non-upgraded.
  • What are the high level differences compared with the previous version (f.e. loss based estimator) and the impact (pros and cons).
  • What changes have been made in this PR compared with the official libwebrtc branch, both in terms of code and non default configuration. Including the reason of those changes as well as the testing done and implications.
  • What is the testing that has been done in this branch (what network scenarios) and what are the results of those tests compared with the same tests in the v3 branch.

That info would be great for people like me to understand the implications of the change and maybe could help to move it forward.

Just an idea

@jmillan
Copy link
Member

jmillan commented Jul 14, 2023

That info would be great for people like me to understand the implications of the change and maybe could help to move it forward.

@ggarber, @vpalmisano and anyone interested. Here the report for all the research and changes @sarumjanuch did on this PR.

https://teamaround.notion.site/BWE-research-report-4e3a371d04fd4b7889c64c0321fa950c

Let's leave this PR as a space for any question or comment about it.

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

Successfully merging this pull request may close these issues.

signed-to-unsigned overflow in send_side_bandwidth_estimation.cc min_pending_time should not be negative
9 participants