Remove the KeyProtocol metric

Now that SDES is (largely) removed, this is no longer useful.

Bug: chromium:1365484
Change-Id: I3e626a7d5d83130a70958851de3df0aa27616bd2
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/277781
Reviewed-by: Henrik Boström <hbos@webrtc.org>
Commit-Queue: Harald Alvestrand <hta@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#38278}
This commit is contained in:
Harald Alvestrand 2022-10-03 13:16:28 +00:00 committed by WebRTC LUCI CQ
parent f30bf5b746
commit 22d32f1a6c
3 changed files with 3 additions and 28 deletions

View File

@ -83,14 +83,6 @@ enum IceCandidatePairType {
// occurrences of events, while "Name" has a value associated with it which is
// used to form a histogram.
// These values are persisted to logs. Entries should not be renumbered and
// numeric values should never be reused.
enum KeyExchangeProtocolType {
kEnumCounterKeyProtocolDtls = 0,
kEnumCounterKeyProtocolSdes = 1,
kEnumCounterKeyProtocolMax
};
// These values are persisted to logs. Entries should not be renumbered and
// numeric values should never be reused.
enum KeyExchangeProtocolMedia {

View File

@ -268,12 +268,6 @@ TEST_P(PeerConnectionIntegrationTest, EndToEndCallWithDtls) {
MediaExpectations media_expectations;
media_expectations.ExpectBidirectionalAudioAndVideo();
ASSERT_TRUE(ExpectNewFrames(media_expectations));
EXPECT_METRIC_LE(
2, webrtc::metrics::NumEvents("WebRTC.PeerConnection.KeyProtocol",
webrtc::kEnumCounterKeyProtocolDtls));
EXPECT_METRIC_EQ(
0, webrtc::metrics::NumEvents("WebRTC.PeerConnection.KeyProtocol",
webrtc::kEnumCounterKeyProtocolSdes));
}
#if defined(WEBRTC_FUCHSIA)
@ -293,12 +287,6 @@ TEST_P(PeerConnectionIntegrationTest, EndToEndCallWithSdes) {
MediaExpectations media_expectations;
media_expectations.ExpectBidirectionalAudioAndVideo();
ASSERT_TRUE(ExpectNewFrames(media_expectations));
EXPECT_METRIC_LE(
2, webrtc::metrics::NumEvents("WebRTC.PeerConnection.KeyProtocol",
webrtc::kEnumCounterKeyProtocolSdes));
EXPECT_METRIC_EQ(
0, webrtc::metrics::NumEvents("WebRTC.PeerConnection.KeyProtocol",
webrtc::kEnumCounterKeyProtocolDtls));
}
#endif

View File

@ -133,11 +133,6 @@ void NoteAddIceCandidateResult(int result) {
kAddIceCandidateMax);
}
void NoteKeyProtocol(KeyExchangeProtocolType protocol_type) {
RTC_HISTOGRAM_ENUMERATION("WebRTC.PeerConnection.KeyProtocol", protocol_type,
kEnumCounterKeyProtocolMax);
}
std::map<std::string, const cricket::ContentGroup*> GetBundleGroupsByMid(
const SessionDescription* desc) {
std::vector<const cricket::ContentGroup*> bundle_groups =
@ -331,9 +326,9 @@ RTCError VerifyCrypto(const SessionDescription* desc,
if (content_info.rejected) {
continue;
}
// Note what media is used with each crypto protocol, for all sections.
NoteKeyProtocol(dtls_enabled ? webrtc::kEnumCounterKeyProtocolDtls
: webrtc::kEnumCounterKeyProtocolSdes);
#if !defined(WEBRTC_FUCHSIA)
RTC_CHECK(dtls_enabled) << "SDES protocol is only allowed in Fuchsia";
#endif
const std::string& mid = content_info.name;
auto it = bundle_groups_by_mid.find(mid);
const cricket::ContentGroup* bundle =