From 32e6fc3c42622f30fad469d6ed2a5ac3700b1ec0 Mon Sep 17 00:00:00 2001 From: hai007 Date: Mon, 24 Oct 2022 19:05:30 -0700 Subject: [PATCH] Previously, we log incoming remote endpoint upgrade failure and local upgrade setup failure incorrectly as CHANNEL_ERROR. In this CL, they are logged as REMOTE_CONNECTION_ERROR and xxx_MEDIUM_ERROR instead. Note that the user can always filter out these errors if necessary. Update isAbnormalUpgradeFailure() check as part of upgrade failure reason code change. In addition, skip incoming/outgoing upgrade logging only if the upgrade fails and initial connection is already removed. PiperOrigin-RevId: 483545395 --- proto/connections_enums.proto | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/proto/connections_enums.proto b/proto/connections_enums.proto index 95a42a63..cf3adbb1 100644 --- a/proto/connections_enums.proto +++ b/proto/connections_enums.proto @@ -219,7 +219,7 @@ enum Bandwidth { } // LINT.IfChange -// next_id: 19 +// next_id: 20 // Result of an upgrade attempt. enum BandwidthUpgradeResult { UNKNOWN_BANDWIDTH_UPGRADE_RESULT = 0; @@ -271,6 +271,9 @@ enum BandwidthUpgradeResult { // The attempt was never made because a precondition check failed. ATTEMPT_SKIPPED = 18; + + // When the remote endpoint fails to connect + REMOTE_CONNECTION_ERROR = 19; } // LINT.ThenChange( // //depot/google3/wireless/android/stats/platform/westworld/public/protos/enums/android/nearby/connections/enums.proto