Index: talk/app/webrtc/umametrics.h |
diff --git a/talk/app/webrtc/umametrics.h b/talk/app/webrtc/umametrics.h |
index bb9e05230d35cb0cb7dff3de24515625cd30a6f9..37e7b6de423c1d7b9dc51a7720b7aa65df891024 100644 |
--- a/talk/app/webrtc/umametrics.h |
+++ b/talk/app/webrtc/umametrics.h |
@@ -32,11 +32,24 @@ |
namespace webrtc { |
+// Used to specify which enum counter type we're incrementing in |
+// MetricsObserverInterface::IncrementEnumCounter. |
+enum PeerConnectionEnumCounterType { |
+ kEnumCounterAddressFamily, |
+ // For the next 2 counters, we track them separately based on the "first hop" |
+ // protocol used by the local candidate. "First hop" means the local candidate |
+ // type in the case of non-TURN candidates, and the protocol used to connect |
+ // to the TURN server in the case of TURN candidates. |
+ kEnumCounterIceCandidatePairTypeUdp, |
+ kEnumCounterIceCandidatePairTypeTcp, |
+ kPeerConnectionEnumCounterMax |
+}; |
+ |
// Currently this contains information related to WebRTC network/transport |
// information. |
-// The difference between PeerConnectionMetricsCounter and |
-// PeerConnectionMetricsName is that the "Counter" is only counting the |
+// The difference between PeerConnectionEnumCounter and |
+// PeerConnectionMetricsName is that the "EnumCounter" is only counting the |
// occurrences of events, while "Name" has a value associated with it which is |
// used to form a histogram. |
@@ -44,19 +57,19 @@ namespace webrtc { |
// chromium/src/tools/metrics/histograms/histograms.xml |
// Existing values cannot be re-ordered and new enums must be added |
// before kBoundary. |
-enum PeerConnectionMetricsCounter { |
+enum PeerConnectionAddressFamilyCounter { |
kPeerConnection_IPv4, |
kPeerConnection_IPv6, |
kBestConnections_IPv4, |
kBestConnections_IPv6, |
- kPeerConnectionMetricsCounter_Max, |
+ kPeerConnectionAddressFamilyCounter_Max, |
}; |
// TODO(guoweis): Keep previous name here until all references are renamed. |
-#define kBoundary kPeerConnectionMetricsCounter_Max |
+#define kBoundary kPeerConnectionAddressFamilyCounter_Max |
// TODO(guoweis): Keep previous name here until all references are renamed. |
-typedef PeerConnectionMetricsCounter PeerConnectionUMAMetricsCounter; |
+typedef PeerConnectionAddressFamilyCounter PeerConnectionUMAMetricsCounter; |
// This enum defines types for UMA samples, which will have a range. |
enum PeerConnectionMetricsName { |
@@ -77,6 +90,29 @@ enum PeerConnectionMetricsName { |
// TODO(guoweis): Keep previous name here until all references are renamed. |
typedef PeerConnectionMetricsName PeerConnectionUMAMetricsName; |
+// The IceCandidatePairType has the format of |
+// <local_candidate_type>_<remote_candidate_type>. It is recorded based on the |
+// type of candidate pair used when the PeerConnection first goes to a completed |
+// state. When BUNDLE is enabled, only the first transport gets recorded. |
+enum IceCandidatePairType { |
+ kIceCandidatePairHostHost, |
+ kIceCandidatePairHostSrflx, |
+ kIceCandidatePairHostRelay, |
+ kIceCandidatePairHostPrflx, |
+ kIceCandidatePairSrflxHost, |
+ kIceCandidatePairSrflxSrflx, |
+ kIceCandidatePairSrflxRelay, |
+ kIceCandidatePairSrflxPrflx, |
+ kIceCandidatePairRelayHost, |
+ kIceCandidatePairRelaySrflx, |
+ kIceCandidatePairRelayRelay, |
+ kIceCandidatePairRelayPrflx, |
+ kIceCandidatePairPrflxHost, |
+ kIceCandidatePairPrflxSrflx, |
+ kIceCandidatePairPrflxRelay, |
+ kIceCandidatePairMax |
+}; |
+ |
} // namespace webrtc |
-#endif // TALK_APP_WEBRTC_UMA6METRICS_H_ |
+#endif // TALK_APP_WEBRTC_UMAMETRICS_H_ |