1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
ash / components / arc / session / arc_vm_data_migration_status.h [blame]
// Copyright 2022 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef ASH_COMPONENTS_ARC_SESSION_ARC_VM_DATA_MIGRATION_STATUS_H_
#define ASH_COMPONENTS_ARC_SESSION_ARC_VM_DATA_MIGRATION_STATUS_H_
#include <ostream>
namespace arc {
constexpr char kArcVmDataMigrationStatusOnArcStartedHistogramName[] =
"Arc.VmDataMigration.MigrationStatusOnArcStarted";
constexpr char kArcVmDataMigrationFinishReasonHistogramName[] =
"Arc.VmDataMigration.MigrationFinishReason";
// These values are persisted to logs. Entries should not be renumbered and
// numeric values should never be reused. Please keep in sync with
// "ArcVmDataMigrationStatus" in tools/metrics/histograms/enums.xml.
enum class ArcVmDataMigrationStatus {
// The user has not been notified of the /data migration.
kUnnotified = 0,
// The user has been notified of the availability of the /data migration via a
// notification.
kNotified = 1,
// The user has confirmed the migration. The actual migration will be
// triggered after a Chrome restart.
kConfirmed = 2,
// The migration has been started and will be resumed upon the next login.
kStarted = 3,
// The migration has been completed and not needed anymore.
kFinished = 4,
kMaxValue = kFinished,
};
// These values are persisted to logs. Entries should not be renumbered and
// numeric values should never be reused. Please keep in sync with
// "ArcVmDataMigrationFinishReason" in tools/metrics/histograms/enums.xml.
enum class ArcVmDataMigrationFinishReason {
// There is no /data to migrate, so virtio-blk can be just enabled.
kNoDataToMigrate = 0,
// Migration finishes successfully.
kMigrationSuccess = 1,
// Migration fails, resulting in enabling virtio-blk on wiped /data.
kMigrationFailure = 2,
kMaxValue = kMigrationFailure,
};
enum class ArcVmDataMigrationStrategy {
// The user should not be prompted to go through /data migration.
kDoNotPrompt = 0,
// The user should be prompted to go through /data migration via
// a notification.
kPrompt = 1,
kMaxValue = kPrompt,
};
std::ostream& operator<<(std::ostream& os, ArcVmDataMigrationStatus status);
} // namespace arc
#endif // ASH_COMPONENTS_ARC_SESSION_ARC_VM_DATA_MIGRATION_STATUS_H_