webrtc_m130/modules/congestion_controller/include/send_side_congestion_controller.h

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

197 lines
8.0 KiB
C
Raw Normal View History

/*
* Copyright (c) 2012 The WebRTC project authors. All Rights Reserved.
*
* Use of this source code is governed by a BSD-style license
* that can be found in the LICENSE file in the root of the source
* tree. An additional intellectual property rights grant can be found
* in the file PATENTS. All contributing project authors may
* be found in the AUTHORS file in the root of the source tree.
*/
#ifndef MODULES_CONGESTION_CONTROLLER_INCLUDE_SEND_SIDE_CONGESTION_CONTROLLER_H_
#define MODULES_CONGESTION_CONTROLLER_INCLUDE_SEND_SIDE_CONGESTION_CONTROLLER_H_
Revert "Revert "Reland "Moved congestion controller to task queue.""" This reverts commit 4e849f6925b2ac44b0957a228d7131fc391fca54. Reason for revert: <INSERT REASONING HERE> Original change's description: > Revert "Reland "Moved congestion controller to task queue."" > > This reverts commit 57daeb7ac7f3d80992905b53fea500953fcfd793. > > Reason for revert: Cause increased congestion and deadlocks in downstream project > > Original change's description: > > Reland "Moved congestion controller to task queue." > > > > This is a reland of 0cbcba7ea0dced1a7f353c64d6cf91d46ccb29f9. > > > > Original change's description: > > > Moved congestion controller to task queue. > > > > > > The goal of this work is to make it easier to experiment with the > > > bandwidth estimation implementation. For this reason network control > > > functionality is moved from SendSideCongestionController(SSCC), > > > PacedSender and BitrateController to the newly created > > > GoogCcNetworkController which implements the newly created > > > NetworkControllerInterface. This allows the implementation to be > > > replaced at runtime in the future. > > > > > > This is the first part of a split of a larger CL, see: > > > https://webrtc-review.googlesource.com/c/src/+/39788/8 > > > For further explanations. > > > > > > Bug: webrtc:8415 > > > Change-Id: I770189c04cc31b313bd4e57821acff55fbcb1ad3 > > > Reviewed-on: https://webrtc-review.googlesource.com/43840 > > > Commit-Queue: Sebastian Jansson <srte@webrtc.org> > > > Reviewed-by: Björn Terelius <terelius@webrtc.org> > > > Reviewed-by: Stefan Holmer <stefan@webrtc.org> > > > Cr-Commit-Position: refs/heads/master@{#21868} > > > > Bug: webrtc:8415 > > Change-Id: I1d1756a30deed5b421b1c91c1918a13b6bb455da > > Reviewed-on: https://webrtc-review.googlesource.com/48000 > > Reviewed-by: Stefan Holmer <stefan@webrtc.org> > > Commit-Queue: Sebastian Jansson <srte@webrtc.org> > > Cr-Commit-Position: refs/heads/master@{#21899} > > TBR=terelius@webrtc.org,stefan@webrtc.org,srte@webrtc.org > > # Not skipping CQ checks because original CL landed > 1 day ago. > > Bug: webrtc:8415 > Change-Id: Ida8074dcac2cc28b3629228eb22846d8a8e81b83 > Reviewed-on: https://webrtc-review.googlesource.com/52980 > Reviewed-by: Danil Chapovalov <danilchap@webrtc.org> > Commit-Queue: Danil Chapovalov <danilchap@webrtc.org> > Cr-Commit-Position: refs/heads/master@{#22017} TBR=danilchap@webrtc.org,terelius@webrtc.org,stefan@webrtc.org,srte@webrtc.org Change-Id: I3393b74370c4f4d0955f50728005b2b925be169b No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: webrtc:8415 Reviewed-on: https://webrtc-review.googlesource.com/53262 Reviewed-by: Sebastian Jansson <srte@webrtc.org> Commit-Queue: Sebastian Jansson <srte@webrtc.org> Cr-Commit-Position: refs/heads/master@{#22023}
2018-02-14 16:50:17 +00:00
#include <atomic>
#include <functional>
#include <map>
#include <memory>
#include <vector>
#include "common_types.h" // NOLINT(build/include)
Revert "Revert "Reland "Moved congestion controller to task queue.""" This reverts commit 4e849f6925b2ac44b0957a228d7131fc391fca54. Reason for revert: <INSERT REASONING HERE> Original change's description: > Revert "Reland "Moved congestion controller to task queue."" > > This reverts commit 57daeb7ac7f3d80992905b53fea500953fcfd793. > > Reason for revert: Cause increased congestion and deadlocks in downstream project > > Original change's description: > > Reland "Moved congestion controller to task queue." > > > > This is a reland of 0cbcba7ea0dced1a7f353c64d6cf91d46ccb29f9. > > > > Original change's description: > > > Moved congestion controller to task queue. > > > > > > The goal of this work is to make it easier to experiment with the > > > bandwidth estimation implementation. For this reason network control > > > functionality is moved from SendSideCongestionController(SSCC), > > > PacedSender and BitrateController to the newly created > > > GoogCcNetworkController which implements the newly created > > > NetworkControllerInterface. This allows the implementation to be > > > replaced at runtime in the future. > > > > > > This is the first part of a split of a larger CL, see: > > > https://webrtc-review.googlesource.com/c/src/+/39788/8 > > > For further explanations. > > > > > > Bug: webrtc:8415 > > > Change-Id: I770189c04cc31b313bd4e57821acff55fbcb1ad3 > > > Reviewed-on: https://webrtc-review.googlesource.com/43840 > > > Commit-Queue: Sebastian Jansson <srte@webrtc.org> > > > Reviewed-by: Björn Terelius <terelius@webrtc.org> > > > Reviewed-by: Stefan Holmer <stefan@webrtc.org> > > > Cr-Commit-Position: refs/heads/master@{#21868} > > > > Bug: webrtc:8415 > > Change-Id: I1d1756a30deed5b421b1c91c1918a13b6bb455da > > Reviewed-on: https://webrtc-review.googlesource.com/48000 > > Reviewed-by: Stefan Holmer <stefan@webrtc.org> > > Commit-Queue: Sebastian Jansson <srte@webrtc.org> > > Cr-Commit-Position: refs/heads/master@{#21899} > > TBR=terelius@webrtc.org,stefan@webrtc.org,srte@webrtc.org > > # Not skipping CQ checks because original CL landed > 1 day ago. > > Bug: webrtc:8415 > Change-Id: Ida8074dcac2cc28b3629228eb22846d8a8e81b83 > Reviewed-on: https://webrtc-review.googlesource.com/52980 > Reviewed-by: Danil Chapovalov <danilchap@webrtc.org> > Commit-Queue: Danil Chapovalov <danilchap@webrtc.org> > Cr-Commit-Position: refs/heads/master@{#22017} TBR=danilchap@webrtc.org,terelius@webrtc.org,stefan@webrtc.org,srte@webrtc.org Change-Id: I3393b74370c4f4d0955f50728005b2b925be169b No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: webrtc:8415 Reviewed-on: https://webrtc-review.googlesource.com/53262 Reviewed-by: Sebastian Jansson <srte@webrtc.org> Commit-Queue: Sebastian Jansson <srte@webrtc.org> Cr-Commit-Position: refs/heads/master@{#22023}
2018-02-14 16:50:17 +00:00
#include "modules/congestion_controller/network_control/include/network_control.h"
#include "modules/congestion_controller/network_control/include/network_types.h"
#include "modules/congestion_controller/pacer_controller.h"
#include "modules/congestion_controller/transport_feedback_adapter.h"
#include "modules/include/module.h"
#include "modules/include/module_common_types.h"
#include "modules/pacing/paced_sender.h"
Revert "Revert "Reland "Moved congestion controller to task queue.""" This reverts commit 4e849f6925b2ac44b0957a228d7131fc391fca54. Reason for revert: <INSERT REASONING HERE> Original change's description: > Revert "Reland "Moved congestion controller to task queue."" > > This reverts commit 57daeb7ac7f3d80992905b53fea500953fcfd793. > > Reason for revert: Cause increased congestion and deadlocks in downstream project > > Original change's description: > > Reland "Moved congestion controller to task queue." > > > > This is a reland of 0cbcba7ea0dced1a7f353c64d6cf91d46ccb29f9. > > > > Original change's description: > > > Moved congestion controller to task queue. > > > > > > The goal of this work is to make it easier to experiment with the > > > bandwidth estimation implementation. For this reason network control > > > functionality is moved from SendSideCongestionController(SSCC), > > > PacedSender and BitrateController to the newly created > > > GoogCcNetworkController which implements the newly created > > > NetworkControllerInterface. This allows the implementation to be > > > replaced at runtime in the future. > > > > > > This is the first part of a split of a larger CL, see: > > > https://webrtc-review.googlesource.com/c/src/+/39788/8 > > > For further explanations. > > > > > > Bug: webrtc:8415 > > > Change-Id: I770189c04cc31b313bd4e57821acff55fbcb1ad3 > > > Reviewed-on: https://webrtc-review.googlesource.com/43840 > > > Commit-Queue: Sebastian Jansson <srte@webrtc.org> > > > Reviewed-by: Björn Terelius <terelius@webrtc.org> > > > Reviewed-by: Stefan Holmer <stefan@webrtc.org> > > > Cr-Commit-Position: refs/heads/master@{#21868} > > > > Bug: webrtc:8415 > > Change-Id: I1d1756a30deed5b421b1c91c1918a13b6bb455da > > Reviewed-on: https://webrtc-review.googlesource.com/48000 > > Reviewed-by: Stefan Holmer <stefan@webrtc.org> > > Commit-Queue: Sebastian Jansson <srte@webrtc.org> > > Cr-Commit-Position: refs/heads/master@{#21899} > > TBR=terelius@webrtc.org,stefan@webrtc.org,srte@webrtc.org > > # Not skipping CQ checks because original CL landed > 1 day ago. > > Bug: webrtc:8415 > Change-Id: Ida8074dcac2cc28b3629228eb22846d8a8e81b83 > Reviewed-on: https://webrtc-review.googlesource.com/52980 > Reviewed-by: Danil Chapovalov <danilchap@webrtc.org> > Commit-Queue: Danil Chapovalov <danilchap@webrtc.org> > Cr-Commit-Position: refs/heads/master@{#22017} TBR=danilchap@webrtc.org,terelius@webrtc.org,stefan@webrtc.org,srte@webrtc.org Change-Id: I3393b74370c4f4d0955f50728005b2b925be169b No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: webrtc:8415 Reviewed-on: https://webrtc-review.googlesource.com/53262 Reviewed-by: Sebastian Jansson <srte@webrtc.org> Commit-Queue: Sebastian Jansson <srte@webrtc.org> Cr-Commit-Position: refs/heads/master@{#22023}
2018-02-14 16:50:17 +00:00
#include "modules/rtp_rtcp/include/rtp_rtcp_defines.h"
#include "rtc_base/constructormagic.h"
#include "rtc_base/criticalsection.h"
#include "rtc_base/networkroute.h"
#include "rtc_base/race_checker.h"
Revert "Revert "Reland "Moved congestion controller to task queue.""" This reverts commit 4e849f6925b2ac44b0957a228d7131fc391fca54. Reason for revert: <INSERT REASONING HERE> Original change's description: > Revert "Reland "Moved congestion controller to task queue."" > > This reverts commit 57daeb7ac7f3d80992905b53fea500953fcfd793. > > Reason for revert: Cause increased congestion and deadlocks in downstream project > > Original change's description: > > Reland "Moved congestion controller to task queue." > > > > This is a reland of 0cbcba7ea0dced1a7f353c64d6cf91d46ccb29f9. > > > > Original change's description: > > > Moved congestion controller to task queue. > > > > > > The goal of this work is to make it easier to experiment with the > > > bandwidth estimation implementation. For this reason network control > > > functionality is moved from SendSideCongestionController(SSCC), > > > PacedSender and BitrateController to the newly created > > > GoogCcNetworkController which implements the newly created > > > NetworkControllerInterface. This allows the implementation to be > > > replaced at runtime in the future. > > > > > > This is the first part of a split of a larger CL, see: > > > https://webrtc-review.googlesource.com/c/src/+/39788/8 > > > For further explanations. > > > > > > Bug: webrtc:8415 > > > Change-Id: I770189c04cc31b313bd4e57821acff55fbcb1ad3 > > > Reviewed-on: https://webrtc-review.googlesource.com/43840 > > > Commit-Queue: Sebastian Jansson <srte@webrtc.org> > > > Reviewed-by: Björn Terelius <terelius@webrtc.org> > > > Reviewed-by: Stefan Holmer <stefan@webrtc.org> > > > Cr-Commit-Position: refs/heads/master@{#21868} > > > > Bug: webrtc:8415 > > Change-Id: I1d1756a30deed5b421b1c91c1918a13b6bb455da > > Reviewed-on: https://webrtc-review.googlesource.com/48000 > > Reviewed-by: Stefan Holmer <stefan@webrtc.org> > > Commit-Queue: Sebastian Jansson <srte@webrtc.org> > > Cr-Commit-Position: refs/heads/master@{#21899} > > TBR=terelius@webrtc.org,stefan@webrtc.org,srte@webrtc.org > > # Not skipping CQ checks because original CL landed > 1 day ago. > > Bug: webrtc:8415 > Change-Id: Ida8074dcac2cc28b3629228eb22846d8a8e81b83 > Reviewed-on: https://webrtc-review.googlesource.com/52980 > Reviewed-by: Danil Chapovalov <danilchap@webrtc.org> > Commit-Queue: Danil Chapovalov <danilchap@webrtc.org> > Cr-Commit-Position: refs/heads/master@{#22017} TBR=danilchap@webrtc.org,terelius@webrtc.org,stefan@webrtc.org,srte@webrtc.org Change-Id: I3393b74370c4f4d0955f50728005b2b925be169b No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: webrtc:8415 Reviewed-on: https://webrtc-review.googlesource.com/53262 Reviewed-by: Sebastian Jansson <srte@webrtc.org> Commit-Queue: Sebastian Jansson <srte@webrtc.org> Cr-Commit-Position: refs/heads/master@{#22023}
2018-02-14 16:50:17 +00:00
#include "rtc_base/task_queue.h"
namespace rtc {
struct SentPacket;
}
namespace webrtc {
class Clock;
class RateLimiter;
class RtcEventLog;
Revert "Revert "Reland "Moved congestion controller to task queue.""" This reverts commit 4e849f6925b2ac44b0957a228d7131fc391fca54. Reason for revert: <INSERT REASONING HERE> Original change's description: > Revert "Reland "Moved congestion controller to task queue."" > > This reverts commit 57daeb7ac7f3d80992905b53fea500953fcfd793. > > Reason for revert: Cause increased congestion and deadlocks in downstream project > > Original change's description: > > Reland "Moved congestion controller to task queue." > > > > This is a reland of 0cbcba7ea0dced1a7f353c64d6cf91d46ccb29f9. > > > > Original change's description: > > > Moved congestion controller to task queue. > > > > > > The goal of this work is to make it easier to experiment with the > > > bandwidth estimation implementation. For this reason network control > > > functionality is moved from SendSideCongestionController(SSCC), > > > PacedSender and BitrateController to the newly created > > > GoogCcNetworkController which implements the newly created > > > NetworkControllerInterface. This allows the implementation to be > > > replaced at runtime in the future. > > > > > > This is the first part of a split of a larger CL, see: > > > https://webrtc-review.googlesource.com/c/src/+/39788/8 > > > For further explanations. > > > > > > Bug: webrtc:8415 > > > Change-Id: I770189c04cc31b313bd4e57821acff55fbcb1ad3 > > > Reviewed-on: https://webrtc-review.googlesource.com/43840 > > > Commit-Queue: Sebastian Jansson <srte@webrtc.org> > > > Reviewed-by: Björn Terelius <terelius@webrtc.org> > > > Reviewed-by: Stefan Holmer <stefan@webrtc.org> > > > Cr-Commit-Position: refs/heads/master@{#21868} > > > > Bug: webrtc:8415 > > Change-Id: I1d1756a30deed5b421b1c91c1918a13b6bb455da > > Reviewed-on: https://webrtc-review.googlesource.com/48000 > > Reviewed-by: Stefan Holmer <stefan@webrtc.org> > > Commit-Queue: Sebastian Jansson <srte@webrtc.org> > > Cr-Commit-Position: refs/heads/master@{#21899} > > TBR=terelius@webrtc.org,stefan@webrtc.org,srte@webrtc.org > > # Not skipping CQ checks because original CL landed > 1 day ago. > > Bug: webrtc:8415 > Change-Id: Ida8074dcac2cc28b3629228eb22846d8a8e81b83 > Reviewed-on: https://webrtc-review.googlesource.com/52980 > Reviewed-by: Danil Chapovalov <danilchap@webrtc.org> > Commit-Queue: Danil Chapovalov <danilchap@webrtc.org> > Cr-Commit-Position: refs/heads/master@{#22017} TBR=danilchap@webrtc.org,terelius@webrtc.org,stefan@webrtc.org,srte@webrtc.org Change-Id: I3393b74370c4f4d0955f50728005b2b925be169b No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: webrtc:8415 Reviewed-on: https://webrtc-review.googlesource.com/53262 Reviewed-by: Sebastian Jansson <srte@webrtc.org> Commit-Queue: Sebastian Jansson <srte@webrtc.org> Cr-Commit-Position: refs/heads/master@{#22023}
2018-02-14 16:50:17 +00:00
namespace send_side_cc_internal {
// This is used to observe the network controller state and route calls to
// the proper handler. It also keeps cached values for safe asynchronous use.
// This makes sure that things running on the worker queue can't access state
// in SendSideCongestionController, which would risk causing data race on
// destruction unless members are properly ordered.
class ControlHandler;
} // namespace send_side_cc_internal
class SendSideCongestionController : public CallStatsObserver,
public Module,
Revert "Revert "Reland "Moved congestion controller to task queue.""" This reverts commit 4e849f6925b2ac44b0957a228d7131fc391fca54. Reason for revert: <INSERT REASONING HERE> Original change's description: > Revert "Reland "Moved congestion controller to task queue."" > > This reverts commit 57daeb7ac7f3d80992905b53fea500953fcfd793. > > Reason for revert: Cause increased congestion and deadlocks in downstream project > > Original change's description: > > Reland "Moved congestion controller to task queue." > > > > This is a reland of 0cbcba7ea0dced1a7f353c64d6cf91d46ccb29f9. > > > > Original change's description: > > > Moved congestion controller to task queue. > > > > > > The goal of this work is to make it easier to experiment with the > > > bandwidth estimation implementation. For this reason network control > > > functionality is moved from SendSideCongestionController(SSCC), > > > PacedSender and BitrateController to the newly created > > > GoogCcNetworkController which implements the newly created > > > NetworkControllerInterface. This allows the implementation to be > > > replaced at runtime in the future. > > > > > > This is the first part of a split of a larger CL, see: > > > https://webrtc-review.googlesource.com/c/src/+/39788/8 > > > For further explanations. > > > > > > Bug: webrtc:8415 > > > Change-Id: I770189c04cc31b313bd4e57821acff55fbcb1ad3 > > > Reviewed-on: https://webrtc-review.googlesource.com/43840 > > > Commit-Queue: Sebastian Jansson <srte@webrtc.org> > > > Reviewed-by: Björn Terelius <terelius@webrtc.org> > > > Reviewed-by: Stefan Holmer <stefan@webrtc.org> > > > Cr-Commit-Position: refs/heads/master@{#21868} > > > > Bug: webrtc:8415 > > Change-Id: I1d1756a30deed5b421b1c91c1918a13b6bb455da > > Reviewed-on: https://webrtc-review.googlesource.com/48000 > > Reviewed-by: Stefan Holmer <stefan@webrtc.org> > > Commit-Queue: Sebastian Jansson <srte@webrtc.org> > > Cr-Commit-Position: refs/heads/master@{#21899} > > TBR=terelius@webrtc.org,stefan@webrtc.org,srte@webrtc.org > > # Not skipping CQ checks because original CL landed > 1 day ago. > > Bug: webrtc:8415 > Change-Id: Ida8074dcac2cc28b3629228eb22846d8a8e81b83 > Reviewed-on: https://webrtc-review.googlesource.com/52980 > Reviewed-by: Danil Chapovalov <danilchap@webrtc.org> > Commit-Queue: Danil Chapovalov <danilchap@webrtc.org> > Cr-Commit-Position: refs/heads/master@{#22017} TBR=danilchap@webrtc.org,terelius@webrtc.org,stefan@webrtc.org,srte@webrtc.org Change-Id: I3393b74370c4f4d0955f50728005b2b925be169b No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: webrtc:8415 Reviewed-on: https://webrtc-review.googlesource.com/53262 Reviewed-by: Sebastian Jansson <srte@webrtc.org> Commit-Queue: Sebastian Jansson <srte@webrtc.org> Cr-Commit-Position: refs/heads/master@{#22023}
2018-02-14 16:50:17 +00:00
public TransportFeedbackObserver,
public RtcpBandwidthObserver {
public:
// Observer class for bitrate changes announced due to change in bandwidth
// estimate or due to that the send pacer is full. Fraction loss and rtt is
// also part of this callback to allow the observer to optimize its settings
// for different types of network environments. The bitrate does not include
// packet headers and is measured in bits per second.
class Observer {
public:
virtual void OnNetworkChanged(uint32_t bitrate_bps,
uint8_t fraction_loss, // 0 - 255.
int64_t rtt_ms,
int64_t probing_interval_ms) = 0;
protected:
virtual ~Observer() {}
};
SendSideCongestionController(const Clock* clock,
Observer* observer,
RtcEventLog* event_log,
PacedSender* pacer);
~SendSideCongestionController() override;
void RegisterPacketFeedbackObserver(PacketFeedbackObserver* observer);
void DeRegisterPacketFeedbackObserver(PacketFeedbackObserver* observer);
// Currently, there can be at most one observer.
// TODO(nisse): The RegisterNetworkObserver method is needed because we first
// construct this object (as part of RtpTransportControllerSend), then pass a
// reference to Call, which then registers itself as the observer. We should
// try to break this circular chain of references, and make the observer a
// construction time constant.
void RegisterNetworkObserver(Observer* observer);
void DeRegisterNetworkObserver(Observer* observer);
virtual void SetBweBitrates(int min_bitrate_bps,
int start_bitrate_bps,
int max_bitrate_bps);
// Resets the BWE state. Note the first argument is the bitrate_bps.
virtual void OnNetworkRouteChanged(const rtc::NetworkRoute& network_route,
int bitrate_bps,
int min_bitrate_bps,
int max_bitrate_bps);
virtual void SignalNetworkState(NetworkState state);
virtual void SetTransportOverhead(size_t transport_overhead_bytes_per_packet);
Revert "Revert "Reland "Moved congestion controller to task queue.""" This reverts commit 4e849f6925b2ac44b0957a228d7131fc391fca54. Reason for revert: <INSERT REASONING HERE> Original change's description: > Revert "Reland "Moved congestion controller to task queue."" > > This reverts commit 57daeb7ac7f3d80992905b53fea500953fcfd793. > > Reason for revert: Cause increased congestion and deadlocks in downstream project > > Original change's description: > > Reland "Moved congestion controller to task queue." > > > > This is a reland of 0cbcba7ea0dced1a7f353c64d6cf91d46ccb29f9. > > > > Original change's description: > > > Moved congestion controller to task queue. > > > > > > The goal of this work is to make it easier to experiment with the > > > bandwidth estimation implementation. For this reason network control > > > functionality is moved from SendSideCongestionController(SSCC), > > > PacedSender and BitrateController to the newly created > > > GoogCcNetworkController which implements the newly created > > > NetworkControllerInterface. This allows the implementation to be > > > replaced at runtime in the future. > > > > > > This is the first part of a split of a larger CL, see: > > > https://webrtc-review.googlesource.com/c/src/+/39788/8 > > > For further explanations. > > > > > > Bug: webrtc:8415 > > > Change-Id: I770189c04cc31b313bd4e57821acff55fbcb1ad3 > > > Reviewed-on: https://webrtc-review.googlesource.com/43840 > > > Commit-Queue: Sebastian Jansson <srte@webrtc.org> > > > Reviewed-by: Björn Terelius <terelius@webrtc.org> > > > Reviewed-by: Stefan Holmer <stefan@webrtc.org> > > > Cr-Commit-Position: refs/heads/master@{#21868} > > > > Bug: webrtc:8415 > > Change-Id: I1d1756a30deed5b421b1c91c1918a13b6bb455da > > Reviewed-on: https://webrtc-review.googlesource.com/48000 > > Reviewed-by: Stefan Holmer <stefan@webrtc.org> > > Commit-Queue: Sebastian Jansson <srte@webrtc.org> > > Cr-Commit-Position: refs/heads/master@{#21899} > > TBR=terelius@webrtc.org,stefan@webrtc.org,srte@webrtc.org > > # Not skipping CQ checks because original CL landed > 1 day ago. > > Bug: webrtc:8415 > Change-Id: Ida8074dcac2cc28b3629228eb22846d8a8e81b83 > Reviewed-on: https://webrtc-review.googlesource.com/52980 > Reviewed-by: Danil Chapovalov <danilchap@webrtc.org> > Commit-Queue: Danil Chapovalov <danilchap@webrtc.org> > Cr-Commit-Position: refs/heads/master@{#22017} TBR=danilchap@webrtc.org,terelius@webrtc.org,stefan@webrtc.org,srte@webrtc.org Change-Id: I3393b74370c4f4d0955f50728005b2b925be169b No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: webrtc:8415 Reviewed-on: https://webrtc-review.googlesource.com/53262 Reviewed-by: Sebastian Jansson <srte@webrtc.org> Commit-Queue: Sebastian Jansson <srte@webrtc.org> Cr-Commit-Position: refs/heads/master@{#22023}
2018-02-14 16:50:17 +00:00
virtual RtcpBandwidthObserver* GetBandwidthObserver();
virtual bool AvailableBandwidth(uint32_t* bandwidth) const;
virtual int64_t GetPacerQueuingDelayMs() const;
virtual int64_t GetFirstPacketTimeMs() const;
virtual TransportFeedbackObserver* GetTransportFeedbackObserver();
RateLimiter* GetRetransmissionRateLimiter();
void EnablePeriodicAlrProbing(bool enable);
virtual void OnSentPacket(const rtc::SentPacket& sent_packet);
Revert "Revert "Reland "Moved congestion controller to task queue.""" This reverts commit 4e849f6925b2ac44b0957a228d7131fc391fca54. Reason for revert: <INSERT REASONING HERE> Original change's description: > Revert "Reland "Moved congestion controller to task queue."" > > This reverts commit 57daeb7ac7f3d80992905b53fea500953fcfd793. > > Reason for revert: Cause increased congestion and deadlocks in downstream project > > Original change's description: > > Reland "Moved congestion controller to task queue." > > > > This is a reland of 0cbcba7ea0dced1a7f353c64d6cf91d46ccb29f9. > > > > Original change's description: > > > Moved congestion controller to task queue. > > > > > > The goal of this work is to make it easier to experiment with the > > > bandwidth estimation implementation. For this reason network control > > > functionality is moved from SendSideCongestionController(SSCC), > > > PacedSender and BitrateController to the newly created > > > GoogCcNetworkController which implements the newly created > > > NetworkControllerInterface. This allows the implementation to be > > > replaced at runtime in the future. > > > > > > This is the first part of a split of a larger CL, see: > > > https://webrtc-review.googlesource.com/c/src/+/39788/8 > > > For further explanations. > > > > > > Bug: webrtc:8415 > > > Change-Id: I770189c04cc31b313bd4e57821acff55fbcb1ad3 > > > Reviewed-on: https://webrtc-review.googlesource.com/43840 > > > Commit-Queue: Sebastian Jansson <srte@webrtc.org> > > > Reviewed-by: Björn Terelius <terelius@webrtc.org> > > > Reviewed-by: Stefan Holmer <stefan@webrtc.org> > > > Cr-Commit-Position: refs/heads/master@{#21868} > > > > Bug: webrtc:8415 > > Change-Id: I1d1756a30deed5b421b1c91c1918a13b6bb455da > > Reviewed-on: https://webrtc-review.googlesource.com/48000 > > Reviewed-by: Stefan Holmer <stefan@webrtc.org> > > Commit-Queue: Sebastian Jansson <srte@webrtc.org> > > Cr-Commit-Position: refs/heads/master@{#21899} > > TBR=terelius@webrtc.org,stefan@webrtc.org,srte@webrtc.org > > # Not skipping CQ checks because original CL landed > 1 day ago. > > Bug: webrtc:8415 > Change-Id: Ida8074dcac2cc28b3629228eb22846d8a8e81b83 > Reviewed-on: https://webrtc-review.googlesource.com/52980 > Reviewed-by: Danil Chapovalov <danilchap@webrtc.org> > Commit-Queue: Danil Chapovalov <danilchap@webrtc.org> > Cr-Commit-Position: refs/heads/master@{#22017} TBR=danilchap@webrtc.org,terelius@webrtc.org,stefan@webrtc.org,srte@webrtc.org Change-Id: I3393b74370c4f4d0955f50728005b2b925be169b No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: webrtc:8415 Reviewed-on: https://webrtc-review.googlesource.com/53262 Reviewed-by: Sebastian Jansson <srte@webrtc.org> Commit-Queue: Sebastian Jansson <srte@webrtc.org> Cr-Commit-Position: refs/heads/master@{#22023}
2018-02-14 16:50:17 +00:00
// Implements RtcpBandwidthObserver
void OnReceivedEstimatedBitrate(uint32_t bitrate) override;
void OnReceivedRtcpReceiverReport(const ReportBlockList& report_blocks,
int64_t rtt,
int64_t now_ms) override;
Revert "Moved congestion controller to task queue." This reverts commit 0cbcba7ea0dced1a7f353c64d6cf91d46ccb29f9. Reason for revert: Major regressions on perf bots. Original change's description: > Moved congestion controller to task queue. > > The goal of this work is to make it easier to experiment with the > bandwidth estimation implementation. For this reason network control > functionality is moved from SendSideCongestionController(SSCC), > PacedSender and BitrateController to the newly created > GoogCcNetworkController which implements the newly created > NetworkControllerInterface. This allows the implementation to be > replaced at runtime in the future. > > This is the first part of a split of a larger CL, see: > https://webrtc-review.googlesource.com/c/src/+/39788/8 > For further explanations. > > Bug: webrtc:8415 > Change-Id: I770189c04cc31b313bd4e57821acff55fbcb1ad3 > Reviewed-on: https://webrtc-review.googlesource.com/43840 > Commit-Queue: Sebastian Jansson <srte@webrtc.org> > Reviewed-by: Björn Terelius <terelius@webrtc.org> > Reviewed-by: Stefan Holmer <stefan@webrtc.org> > Cr-Commit-Position: refs/heads/master@{#21868} TBR=terelius@webrtc.org,stefan@webrtc.org,srte@webrtc.org Change-Id: Ia8a273eb9e92b7d0d960c49658c228208170962d No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: webrtc:8415 Reviewed-on: https://webrtc-review.googlesource.com/47560 Reviewed-by: Sebastian Jansson <srte@webrtc.org> Commit-Queue: Sebastian Jansson <srte@webrtc.org> Cr-Commit-Position: refs/heads/master@{#21877}
2018-02-02 16:55:07 +00:00
// Implements CallStatsObserver.
void OnRttUpdate(int64_t avg_rtt_ms, int64_t max_rtt_ms) override;
// Implements Module.
int64_t TimeUntilNextProcess() override;
void Process() override;
// Implements TransportFeedbackObserver.
void AddPacket(uint32_t ssrc,
uint16_t sequence_number,
size_t length,
const PacedPacketInfo& pacing_info) override;
void OnTransportFeedback(const rtcp::TransportFeedback& feedback) override;
std::vector<PacketFeedback> GetTransportFeedbackVector() const override;
Revert "Revert "Reland "Moved congestion controller to task queue.""" This reverts commit 4e849f6925b2ac44b0957a228d7131fc391fca54. Reason for revert: <INSERT REASONING HERE> Original change's description: > Revert "Reland "Moved congestion controller to task queue."" > > This reverts commit 57daeb7ac7f3d80992905b53fea500953fcfd793. > > Reason for revert: Cause increased congestion and deadlocks in downstream project > > Original change's description: > > Reland "Moved congestion controller to task queue." > > > > This is a reland of 0cbcba7ea0dced1a7f353c64d6cf91d46ccb29f9. > > > > Original change's description: > > > Moved congestion controller to task queue. > > > > > > The goal of this work is to make it easier to experiment with the > > > bandwidth estimation implementation. For this reason network control > > > functionality is moved from SendSideCongestionController(SSCC), > > > PacedSender and BitrateController to the newly created > > > GoogCcNetworkController which implements the newly created > > > NetworkControllerInterface. This allows the implementation to be > > > replaced at runtime in the future. > > > > > > This is the first part of a split of a larger CL, see: > > > https://webrtc-review.googlesource.com/c/src/+/39788/8 > > > For further explanations. > > > > > > Bug: webrtc:8415 > > > Change-Id: I770189c04cc31b313bd4e57821acff55fbcb1ad3 > > > Reviewed-on: https://webrtc-review.googlesource.com/43840 > > > Commit-Queue: Sebastian Jansson <srte@webrtc.org> > > > Reviewed-by: Björn Terelius <terelius@webrtc.org> > > > Reviewed-by: Stefan Holmer <stefan@webrtc.org> > > > Cr-Commit-Position: refs/heads/master@{#21868} > > > > Bug: webrtc:8415 > > Change-Id: I1d1756a30deed5b421b1c91c1918a13b6bb455da > > Reviewed-on: https://webrtc-review.googlesource.com/48000 > > Reviewed-by: Stefan Holmer <stefan@webrtc.org> > > Commit-Queue: Sebastian Jansson <srte@webrtc.org> > > Cr-Commit-Position: refs/heads/master@{#21899} > > TBR=terelius@webrtc.org,stefan@webrtc.org,srte@webrtc.org > > # Not skipping CQ checks because original CL landed > 1 day ago. > > Bug: webrtc:8415 > Change-Id: Ida8074dcac2cc28b3629228eb22846d8a8e81b83 > Reviewed-on: https://webrtc-review.googlesource.com/52980 > Reviewed-by: Danil Chapovalov <danilchap@webrtc.org> > Commit-Queue: Danil Chapovalov <danilchap@webrtc.org> > Cr-Commit-Position: refs/heads/master@{#22017} TBR=danilchap@webrtc.org,terelius@webrtc.org,stefan@webrtc.org,srte@webrtc.org Change-Id: I3393b74370c4f4d0955f50728005b2b925be169b No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: webrtc:8415 Reviewed-on: https://webrtc-review.googlesource.com/53262 Reviewed-by: Sebastian Jansson <srte@webrtc.org> Commit-Queue: Sebastian Jansson <srte@webrtc.org> Cr-Commit-Position: refs/heads/master@{#22023}
2018-02-14 16:50:17 +00:00
// Sets the minimum send bitrate and maximum padding bitrate requested by send
// streams.
// |min_send_bitrate_bps| might be higher that the estimated available network
// bitrate and if so, the pacer will send with |min_send_bitrate_bps|.
// |max_padding_bitrate_bps| might be higher than the estimate available
// network bitrate and if so, the pacer will send padding packets to reach
// the min of the estimated available bitrate and |max_padding_bitrate_bps|.
void SetSendBitrateLimits(int64_t min_send_bitrate_bps,
int64_t max_padding_bitrate_bps);
void SetPacingFactor(float pacing_factor);
protected:
// Waits long enough that any outstanding tasks should be finished.
void WaitOnTasks();
private:
Revert "Revert "Reland "Moved congestion controller to task queue.""" This reverts commit 4e849f6925b2ac44b0957a228d7131fc391fca54. Reason for revert: <INSERT REASONING HERE> Original change's description: > Revert "Reland "Moved congestion controller to task queue."" > > This reverts commit 57daeb7ac7f3d80992905b53fea500953fcfd793. > > Reason for revert: Cause increased congestion and deadlocks in downstream project > > Original change's description: > > Reland "Moved congestion controller to task queue." > > > > This is a reland of 0cbcba7ea0dced1a7f353c64d6cf91d46ccb29f9. > > > > Original change's description: > > > Moved congestion controller to task queue. > > > > > > The goal of this work is to make it easier to experiment with the > > > bandwidth estimation implementation. For this reason network control > > > functionality is moved from SendSideCongestionController(SSCC), > > > PacedSender and BitrateController to the newly created > > > GoogCcNetworkController which implements the newly created > > > NetworkControllerInterface. This allows the implementation to be > > > replaced at runtime in the future. > > > > > > This is the first part of a split of a larger CL, see: > > > https://webrtc-review.googlesource.com/c/src/+/39788/8 > > > For further explanations. > > > > > > Bug: webrtc:8415 > > > Change-Id: I770189c04cc31b313bd4e57821acff55fbcb1ad3 > > > Reviewed-on: https://webrtc-review.googlesource.com/43840 > > > Commit-Queue: Sebastian Jansson <srte@webrtc.org> > > > Reviewed-by: Björn Terelius <terelius@webrtc.org> > > > Reviewed-by: Stefan Holmer <stefan@webrtc.org> > > > Cr-Commit-Position: refs/heads/master@{#21868} > > > > Bug: webrtc:8415 > > Change-Id: I1d1756a30deed5b421b1c91c1918a13b6bb455da > > Reviewed-on: https://webrtc-review.googlesource.com/48000 > > Reviewed-by: Stefan Holmer <stefan@webrtc.org> > > Commit-Queue: Sebastian Jansson <srte@webrtc.org> > > Cr-Commit-Position: refs/heads/master@{#21899} > > TBR=terelius@webrtc.org,stefan@webrtc.org,srte@webrtc.org > > # Not skipping CQ checks because original CL landed > 1 day ago. > > Bug: webrtc:8415 > Change-Id: Ida8074dcac2cc28b3629228eb22846d8a8e81b83 > Reviewed-on: https://webrtc-review.googlesource.com/52980 > Reviewed-by: Danil Chapovalov <danilchap@webrtc.org> > Commit-Queue: Danil Chapovalov <danilchap@webrtc.org> > Cr-Commit-Position: refs/heads/master@{#22017} TBR=danilchap@webrtc.org,terelius@webrtc.org,stefan@webrtc.org,srte@webrtc.org Change-Id: I3393b74370c4f4d0955f50728005b2b925be169b No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: webrtc:8415 Reviewed-on: https://webrtc-review.googlesource.com/53262 Reviewed-by: Sebastian Jansson <srte@webrtc.org> Commit-Queue: Sebastian Jansson <srte@webrtc.org> Cr-Commit-Position: refs/heads/master@{#22023}
2018-02-14 16:50:17 +00:00
SendSideCongestionController(
const Clock* clock,
RtcEventLog* event_log,
PacedSender* pacer,
NetworkControllerFactoryInterface::uptr controller_factory);
void UpdateStreamsConfig();
void WaitOnTask(std::function<void()> closure);
void MaybeUpdateOutstandingData();
void OnReceivedRtcpReceiverReportBlocks(const ReportBlockList& report_blocks,
int64_t now_ms);
const Clock* const clock_;
PacedSender* const pacer_;
TransportFeedbackAdapter transport_feedback_adapter_;
Revert "Revert "Reland "Moved congestion controller to task queue.""" This reverts commit 4e849f6925b2ac44b0957a228d7131fc391fca54. Reason for revert: <INSERT REASONING HERE> Original change's description: > Revert "Reland "Moved congestion controller to task queue."" > > This reverts commit 57daeb7ac7f3d80992905b53fea500953fcfd793. > > Reason for revert: Cause increased congestion and deadlocks in downstream project > > Original change's description: > > Reland "Moved congestion controller to task queue." > > > > This is a reland of 0cbcba7ea0dced1a7f353c64d6cf91d46ccb29f9. > > > > Original change's description: > > > Moved congestion controller to task queue. > > > > > > The goal of this work is to make it easier to experiment with the > > > bandwidth estimation implementation. For this reason network control > > > functionality is moved from SendSideCongestionController(SSCC), > > > PacedSender and BitrateController to the newly created > > > GoogCcNetworkController which implements the newly created > > > NetworkControllerInterface. This allows the implementation to be > > > replaced at runtime in the future. > > > > > > This is the first part of a split of a larger CL, see: > > > https://webrtc-review.googlesource.com/c/src/+/39788/8 > > > For further explanations. > > > > > > Bug: webrtc:8415 > > > Change-Id: I770189c04cc31b313bd4e57821acff55fbcb1ad3 > > > Reviewed-on: https://webrtc-review.googlesource.com/43840 > > > Commit-Queue: Sebastian Jansson <srte@webrtc.org> > > > Reviewed-by: Björn Terelius <terelius@webrtc.org> > > > Reviewed-by: Stefan Holmer <stefan@webrtc.org> > > > Cr-Commit-Position: refs/heads/master@{#21868} > > > > Bug: webrtc:8415 > > Change-Id: I1d1756a30deed5b421b1c91c1918a13b6bb455da > > Reviewed-on: https://webrtc-review.googlesource.com/48000 > > Reviewed-by: Stefan Holmer <stefan@webrtc.org> > > Commit-Queue: Sebastian Jansson <srte@webrtc.org> > > Cr-Commit-Position: refs/heads/master@{#21899} > > TBR=terelius@webrtc.org,stefan@webrtc.org,srte@webrtc.org > > # Not skipping CQ checks because original CL landed > 1 day ago. > > Bug: webrtc:8415 > Change-Id: Ida8074dcac2cc28b3629228eb22846d8a8e81b83 > Reviewed-on: https://webrtc-review.googlesource.com/52980 > Reviewed-by: Danil Chapovalov <danilchap@webrtc.org> > Commit-Queue: Danil Chapovalov <danilchap@webrtc.org> > Cr-Commit-Position: refs/heads/master@{#22017} TBR=danilchap@webrtc.org,terelius@webrtc.org,stefan@webrtc.org,srte@webrtc.org Change-Id: I3393b74370c4f4d0955f50728005b2b925be169b No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: webrtc:8415 Reviewed-on: https://webrtc-review.googlesource.com/53262 Reviewed-by: Sebastian Jansson <srte@webrtc.org> Commit-Queue: Sebastian Jansson <srte@webrtc.org> Cr-Commit-Position: refs/heads/master@{#22023}
2018-02-14 16:50:17 +00:00
const std::unique_ptr<PacerController> pacer_controller_;
const std::unique_ptr<send_side_cc_internal::ControlHandler> control_handler;
const std::unique_ptr<NetworkControllerInterface> controller_;
TimeDelta process_interval_;
int64_t last_process_update_ms_ = 0;
std::map<uint32_t, RTCPReportBlock> last_report_blocks_;
Timestamp last_report_block_time_;
StreamsConfig streams_config_;
const bool send_side_bwe_with_overhead_;
Revert "Revert "Reland "Moved congestion controller to task queue.""" This reverts commit 4e849f6925b2ac44b0957a228d7131fc391fca54. Reason for revert: <INSERT REASONING HERE> Original change's description: > Revert "Reland "Moved congestion controller to task queue."" > > This reverts commit 57daeb7ac7f3d80992905b53fea500953fcfd793. > > Reason for revert: Cause increased congestion and deadlocks in downstream project > > Original change's description: > > Reland "Moved congestion controller to task queue." > > > > This is a reland of 0cbcba7ea0dced1a7f353c64d6cf91d46ccb29f9. > > > > Original change's description: > > > Moved congestion controller to task queue. > > > > > > The goal of this work is to make it easier to experiment with the > > > bandwidth estimation implementation. For this reason network control > > > functionality is moved from SendSideCongestionController(SSCC), > > > PacedSender and BitrateController to the newly created > > > GoogCcNetworkController which implements the newly created > > > NetworkControllerInterface. This allows the implementation to be > > > replaced at runtime in the future. > > > > > > This is the first part of a split of a larger CL, see: > > > https://webrtc-review.googlesource.com/c/src/+/39788/8 > > > For further explanations. > > > > > > Bug: webrtc:8415 > > > Change-Id: I770189c04cc31b313bd4e57821acff55fbcb1ad3 > > > Reviewed-on: https://webrtc-review.googlesource.com/43840 > > > Commit-Queue: Sebastian Jansson <srte@webrtc.org> > > > Reviewed-by: Björn Terelius <terelius@webrtc.org> > > > Reviewed-by: Stefan Holmer <stefan@webrtc.org> > > > Cr-Commit-Position: refs/heads/master@{#21868} > > > > Bug: webrtc:8415 > > Change-Id: I1d1756a30deed5b421b1c91c1918a13b6bb455da > > Reviewed-on: https://webrtc-review.googlesource.com/48000 > > Reviewed-by: Stefan Holmer <stefan@webrtc.org> > > Commit-Queue: Sebastian Jansson <srte@webrtc.org> > > Cr-Commit-Position: refs/heads/master@{#21899} > > TBR=terelius@webrtc.org,stefan@webrtc.org,srte@webrtc.org > > # Not skipping CQ checks because original CL landed > 1 day ago. > > Bug: webrtc:8415 > Change-Id: Ida8074dcac2cc28b3629228eb22846d8a8e81b83 > Reviewed-on: https://webrtc-review.googlesource.com/52980 > Reviewed-by: Danil Chapovalov <danilchap@webrtc.org> > Commit-Queue: Danil Chapovalov <danilchap@webrtc.org> > Cr-Commit-Position: refs/heads/master@{#22017} TBR=danilchap@webrtc.org,terelius@webrtc.org,stefan@webrtc.org,srte@webrtc.org Change-Id: I3393b74370c4f4d0955f50728005b2b925be169b No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: webrtc:8415 Reviewed-on: https://webrtc-review.googlesource.com/53262 Reviewed-by: Sebastian Jansson <srte@webrtc.org> Commit-Queue: Sebastian Jansson <srte@webrtc.org> Cr-Commit-Position: refs/heads/master@{#22023}
2018-02-14 16:50:17 +00:00
std::atomic<size_t> transport_overhead_bytes_per_packet_;
std::atomic<bool> network_available_;
rtc::RaceChecker worker_race_;
Revert "Revert "Reland "Moved congestion controller to task queue.""" This reverts commit 4e849f6925b2ac44b0957a228d7131fc391fca54. Reason for revert: <INSERT REASONING HERE> Original change's description: > Revert "Reland "Moved congestion controller to task queue."" > > This reverts commit 57daeb7ac7f3d80992905b53fea500953fcfd793. > > Reason for revert: Cause increased congestion and deadlocks in downstream project > > Original change's description: > > Reland "Moved congestion controller to task queue." > > > > This is a reland of 0cbcba7ea0dced1a7f353c64d6cf91d46ccb29f9. > > > > Original change's description: > > > Moved congestion controller to task queue. > > > > > > The goal of this work is to make it easier to experiment with the > > > bandwidth estimation implementation. For this reason network control > > > functionality is moved from SendSideCongestionController(SSCC), > > > PacedSender and BitrateController to the newly created > > > GoogCcNetworkController which implements the newly created > > > NetworkControllerInterface. This allows the implementation to be > > > replaced at runtime in the future. > > > > > > This is the first part of a split of a larger CL, see: > > > https://webrtc-review.googlesource.com/c/src/+/39788/8 > > > For further explanations. > > > > > > Bug: webrtc:8415 > > > Change-Id: I770189c04cc31b313bd4e57821acff55fbcb1ad3 > > > Reviewed-on: https://webrtc-review.googlesource.com/43840 > > > Commit-Queue: Sebastian Jansson <srte@webrtc.org> > > > Reviewed-by: Björn Terelius <terelius@webrtc.org> > > > Reviewed-by: Stefan Holmer <stefan@webrtc.org> > > > Cr-Commit-Position: refs/heads/master@{#21868} > > > > Bug: webrtc:8415 > > Change-Id: I1d1756a30deed5b421b1c91c1918a13b6bb455da > > Reviewed-on: https://webrtc-review.googlesource.com/48000 > > Reviewed-by: Stefan Holmer <stefan@webrtc.org> > > Commit-Queue: Sebastian Jansson <srte@webrtc.org> > > Cr-Commit-Position: refs/heads/master@{#21899} > > TBR=terelius@webrtc.org,stefan@webrtc.org,srte@webrtc.org > > # Not skipping CQ checks because original CL landed > 1 day ago. > > Bug: webrtc:8415 > Change-Id: Ida8074dcac2cc28b3629228eb22846d8a8e81b83 > Reviewed-on: https://webrtc-review.googlesource.com/52980 > Reviewed-by: Danil Chapovalov <danilchap@webrtc.org> > Commit-Queue: Danil Chapovalov <danilchap@webrtc.org> > Cr-Commit-Position: refs/heads/master@{#22017} TBR=danilchap@webrtc.org,terelius@webrtc.org,stefan@webrtc.org,srte@webrtc.org Change-Id: I3393b74370c4f4d0955f50728005b2b925be169b No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: webrtc:8415 Reviewed-on: https://webrtc-review.googlesource.com/53262 Reviewed-by: Sebastian Jansson <srte@webrtc.org> Commit-Queue: Sebastian Jansson <srte@webrtc.org> Cr-Commit-Position: refs/heads/master@{#22023}
2018-02-14 16:50:17 +00:00
// Note that moving ownership of the task queue makes it neccessary to make
// sure that there is no outstanding tasks on it using destructed objects.
// This is currently guranteed by using explicit reset in the destructor of
// this class. It is declared last to indicate that it's lifetime is shorter
// than all other members.
std::unique_ptr<rtc::TaskQueue> task_queue_;
RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(SendSideCongestionController);
};
} // namespace webrtc
#endif // MODULES_CONGESTION_CONTROLLER_INCLUDE_SEND_SIDE_CONGESTION_CONTROLLER_H_