New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 660283 link

Starred by 2 users

Issue metadata

Status: Fixed
Owner:
Last visit > 30 days ago
Closed: Nov 19
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Chrome
Pri: 3
Type: Bug



Sign in to add a comment

Fix UpdateEngine.Attempt.ConnectionType UMA metric

Project Member Reported by kirtika@google.com, Oct 28 2016

Issue description

Context for what this metric is, here: https://bugs.chromium.org/p/chromium/issues/detail?id=358339
It records the connection type (wifi, cellular, ethernet) that the device is updating over. 
As of Oct 2016, it is reporting the following distribution:
Unknown: 52%
Wifi: 48%
Ethernet: 00.64%
Rest: ~0

Design doc: https://docs.google.com/document/d/1Ndi0GdvnByfPmlwNgqMHfgVr0CjCg5XvU8w1fvri8f8/edit#heading=h.xgjl2srtytjt

It is not clear what Unknown connection type stands for. Should we consider checking the reporting? 
Current efforts (Oct 2016) that this is a bit relevant to:
(a) impact of network throttling (cellular included) on auto-updates
(b) cellular usage

 
Components: Internals>Installer

Comment 2 by snanda@chromium.org, Feb 20 2018

Components: -Internals>Installer OS>Systems>Network
Labels: OS-Chrome
Cc: ahass...@chromium.org ejcaruso@chromium.org
Components: Internals>Installer
My gut feeling is that kUnknown mostly means "no network connected" or "I forgot to initialize the connection type variable."  I wasn't able to trigger this by hand, but I didn't try very hard either.

I would prefer to have a separate kDisconnected constant to indicate that update_engine checked with shill, and shill is reporting no system connectivity.  kUnknown feels more like "internal error" to me.

It looks like UpdateAttempter::ProcessingDone() can call ScheduleErrorEventAction() which calls PayloadState::UpdateFailed() which calls CollectAndReportAttemptMetrics().  ProcessingDone() will skip this step if status_ == UpdateStatus::REPORTING_ERROR_EVENT or if code == ErrorCode::kSuccess.

Comment 4 Deleted

Owner: ahass...@chromium.org
Status: Assigned (was: Untriaged)
Owner: chowes@google.com
Cc: kirtika@google.com
Project Member

Comment 8 by bugdroid1@chromium.org, Nov 16

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/9a81ea9cb577f7e1ed31e23482532242c313ec43

commit 9a81ea9cb577f7e1ed31e23482532242c313ec43
Author: Colin Howes <chowes@google.com>
Date: Fri Nov 16 19:13:21 2018

Add disconnected connection type for Update Engine

Add a network disconnected connection type to the Update Engine
connection type histogram.

BUG= chromium:660283 

Change-Id: Icc93ec2f49073566dcb49d6abcd70bc535aca176
Reviewed-on: https://chromium-review.googlesource.com/c/1235282
Reviewed-by: Xiaochu Liu <xiaochu@chromium.org>
Commit-Queue: Colin Howes <chowes@google.com>
Cr-Commit-Position: refs/heads/master@{#608884}
[modify] https://crrev.com/9a81ea9cb577f7e1ed31e23482532242c313ec43/tools/metrics/histograms/enums.xml

Project Member

Comment 9 by bugdroid1@chromium.org, Nov 18

The following revision refers to this bug:
  https://chromium.googlesource.com/aosp/platform/system/update_engine/+/c9e98d6995bdd22de37f18e6b175775939d6159d

commit c9e98d6995bdd22de37f18e6b175775939d6159d
Author: Colin Howes <chowes@google.com>
Date: Sun Nov 18 15:11:07 2018

update_engine: Add disconnected network type for metrics reporting

On a failed update, correctly report that the network is disconnected
rather than reporting an "unknown" network type, which is set when the
connection type cannot be determined based on the properties of a given
service path.

BUG= chromium:660283 
TEST=Added relevant unittests. Also tested manually by updating via cros
flash, unplugging Ethernet after the transfer, and killing the
dev_server. Metrics sends "disconnected" as expected.

Change-Id: Ia681b769208b67fb5c14d41a646d816a42ccf33e
Reviewed-on: https://chromium-review.googlesource.com/1231700
Commit-Ready: Colin Howes <chowes@google.com>
Tested-by: Colin Howes <chowes@google.com>
Reviewed-by: Amin Hassani <ahassani@chromium.org>

[modify] https://crrev.com/c9e98d6995bdd22de37f18e6b175775939d6159d/metrics_utils.cc
[modify] https://crrev.com/c9e98d6995bdd22de37f18e6b175775939d6159d/metrics_constants.h
[modify] https://crrev.com/c9e98d6995bdd22de37f18e6b175775939d6159d/connection_manager.cc
[modify] https://crrev.com/c9e98d6995bdd22de37f18e6b175775939d6159d/connection_manager.h
[modify] https://crrev.com/c9e98d6995bdd22de37f18e6b175775939d6159d/metrics_utils_unittest.cc
[modify] https://crrev.com/c9e98d6995bdd22de37f18e6b175775939d6159d/connection_manager_unittest.cc
[modify] https://crrev.com/c9e98d6995bdd22de37f18e6b175775939d6159d/update_manager/boxed_value_unittest.cc
[modify] https://crrev.com/c9e98d6995bdd22de37f18e6b175775939d6159d/connection_utils.cc
[modify] https://crrev.com/c9e98d6995bdd22de37f18e6b175775939d6159d/connection_utils.h

Status: Fixed (was: Assigned)

Sign in to add a comment