Reduce logging frequency in bwe simulations.
BUG=webrtc:5962 NOTRY=true Review-Url: https://codereview.webrtc.org/2030903002 Cr-Commit-Position: refs/heads/master@{#13025}
This commit is contained in:
parent
8f4c77fea1
commit
846b2d9c5c
@ -28,7 +28,8 @@ FullBweSender::FullBweSender(int kbps, BitrateObserver* observer, Clock* clock)
|
||||
clock_(clock),
|
||||
send_time_history_(clock_, 10000),
|
||||
has_received_ack_(false),
|
||||
last_acked_seq_num_(0) {
|
||||
last_acked_seq_num_(0),
|
||||
last_log_time_ms_(0) {
|
||||
assert(kbps >= kMinBitrateKbps);
|
||||
assert(kbps <= kMaxBitrateKbps);
|
||||
bitrate_controller_->SetStartBitrate(1000 * kbps);
|
||||
@ -52,7 +53,11 @@ void FullBweSender::GiveFeedback(const FeedbackPacket& feedback) {
|
||||
std::vector<PacketInfo> packet_feedback_vector(fb.packet_feedback_vector());
|
||||
for (PacketInfo& packet_info : packet_feedback_vector) {
|
||||
if (!send_time_history_.GetInfo(&packet_info, true)) {
|
||||
LOG(LS_WARNING) << "Ack arrived too late.";
|
||||
int64_t now_ms = clock_->TimeInMilliseconds();
|
||||
if (now_ms - last_log_time_ms_ > 5000) {
|
||||
LOG(LS_WARNING) << "Ack arrived too late.";
|
||||
last_log_time_ms_ = now_ms;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -45,6 +45,7 @@ class FullBweSender : public BweSender, public RemoteBitrateObserver {
|
||||
SendTimeHistory send_time_history_;
|
||||
bool has_received_ack_;
|
||||
uint16_t last_acked_seq_num_;
|
||||
int64_t last_log_time_ms_;
|
||||
|
||||
RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(FullBweSender);
|
||||
};
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user