Revert of Add received audio and video call duration metrics based on packets. (patchset #4 id:140001 of https://codereview.webrtc.org/2957073002/ )

Reason for revert:
The following, seemingly related, unit tests crash on Android32 (M Nexus5X).
org.webrtc.PeerConnectionTest#testCompleteSession
org.webrtc.PeerConnectionTest#testDataChannelOnlySession

A Windows build fails with a mysterious compile error.

Original issue's description:
> Add received audio/video call duration metrics based on packets.
>
> Tracks time between first and last audio and packets to successfully pass through Call object's DeliverRtp method, timed with packet timestamps.
>
> BUG=webrtc:7882
>
> Review-Url: https://codereview.webrtc.org/2957073002
> Cr-Commit-Position: refs/heads/master@{#18881}
> Committed: 746749237a

TBR=stefan@webrtc.org,aleloi@webrtc.org,asapersson@webrtc.org,holmer@google.com
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=webrtc:7882

Review-Url: https://codereview.webrtc.org/2972613002
Cr-Commit-Position: refs/heads/master@{#18882}
This commit is contained in:
saza
2017-07-04 01:11:49 -07:00
committed by Commit Bot
parent 746749237a
commit 382f21cd9c
2 changed files with 0 additions and 26 deletions

View File

@ -325,10 +325,6 @@ class Call : public webrtc::Call,
RateCounter received_audio_bytes_per_second_counter_;
RateCounter received_video_bytes_per_second_counter_;
RateCounter received_rtcp_bytes_per_second_counter_;
rtc::Optional<int64_t> first_received_rtp_audio_ms_;
rtc::Optional<int64_t> last_received_rtp_audio_ms_;
rtc::Optional<int64_t> first_received_rtp_video_ms_;
rtc::Optional<int64_t> last_received_rtp_video_ms_;
// TODO(holmer): Remove this lock once BitrateController no longer calls
// OnNetworkChanged from multiple threads.
@ -534,16 +530,6 @@ void Call::UpdateSendHistograms(int64_t first_sent_packet_ms) {
}
void Call::UpdateReceiveHistograms() {
if (first_received_rtp_audio_ms_) {
RTC_HISTOGRAM_COUNTS_100000(
"WebRTC.Call.TimeReceivingAudioRtpPacketsInSeconds",
(*last_received_rtp_audio_ms_ - *first_received_rtp_audio_ms_) / 1000);
}
if (first_received_rtp_video_ms_) {
RTC_HISTOGRAM_COUNTS_100000(
"WebRTC.Call.TimeReceivingVideoRtpPacketsInSeconds",
(*last_received_rtp_video_ms_ - *first_received_rtp_video_ms_) / 1000);
}
const int kMinRequiredPeriodicSamples = 5;
AggregatedStats video_bytes_per_sec =
received_video_bytes_per_second_counter_.GetStats();
@ -1331,11 +1317,6 @@ PacketReceiver::DeliveryStatus Call::DeliverRtp(MediaType media_type,
received_bytes_per_second_counter_.Add(static_cast<int>(length));
received_audio_bytes_per_second_counter_.Add(static_cast<int>(length));
event_log_->LogRtpHeader(kIncomingPacket, packet, length);
const int64_t arrival_time_ms = parsed_packet->arrival_time_ms();
if (!first_received_rtp_audio_ms_) {
first_received_rtp_audio_ms_.emplace(arrival_time_ms);
}
last_received_rtp_audio_ms_.emplace(arrival_time_ms);
return DELIVERY_OK;
}
} else if (media_type == MediaType::VIDEO) {
@ -1343,11 +1324,6 @@ PacketReceiver::DeliveryStatus Call::DeliverRtp(MediaType media_type,
received_bytes_per_second_counter_.Add(static_cast<int>(length));
received_video_bytes_per_second_counter_.Add(static_cast<int>(length));
event_log_->LogRtpHeader(kIncomingPacket, packet, length);
const int64_t arrival_time_ms = parsed_packet->arrival_time_ms();
if (!first_received_rtp_video_ms_) {
first_received_rtp_video_ms_.emplace(arrival_time_ms);
}
last_received_rtp_video_ms_.emplace(arrival_time_ms);
return DELIVERY_OK;
}
}

View File

@ -2644,8 +2644,6 @@ void EndToEndTest::VerifyHistogramStats(bool use_rtx,
// Verify that stats have been updated once.
EXPECT_EQ(2, metrics::NumSamples("WebRTC.Call.LifetimeInSeconds"));
EXPECT_EQ(1, metrics::NumSamples(
"WebRTC.Call.TimeReceivingVideoRtpPacketsInSeconds"));
EXPECT_EQ(1, metrics::NumSamples("WebRTC.Call.VideoBitrateReceivedInKbps"));
EXPECT_EQ(1, metrics::NumSamples("WebRTC.Call.RtcpBitrateReceivedInBps"));
EXPECT_EQ(1, metrics::NumSamples("WebRTC.Call.BitrateReceivedInKbps"));