Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1175)

Unified Diff: components/offline_pages/offline_store_types.h

Issue 2384423003: [Offline pages] Resetting offline page metadata store if initial load fails (Closed)
Patch Set: Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: components/offline_pages/offline_store_types.h
diff --git a/components/offline_pages/offline_store_types.h b/components/offline_pages/offline_store_types.h
index 37c701c203a163619d44cf18365414ecadb9d15f..03ce51c9b4ba070f6d717c70d1bf48ab9a3085ab 100644
--- a/components/offline_pages/offline_store_types.h
+++ b/components/offline_pages/offline_store_types.h
@@ -18,11 +18,18 @@ namespace offline_pages {
// TODO(fgorski): This enum is meant to replace |LoadStatus|.
// Current store state. When LOADED, the store is operational. When
// loading or reset fails, it is reflected appropriately.
+// This enum is used in an UMA histogram. Hence the entries here shouldn't
+// be deleted or re-ordered and new ones should be added to the end.
enum class StoreState {
- NOT_LOADED, // Store is not loaded yet.
- LOADED, // Store is properly loaded and operational.
- FAILED_LOADING, // Store initialization failed.
- FAILED_RESET, // Resetting the store failed.
+ NOT_LOADED, // Store is not loaded yet.
Mark P 2016/10/12 16:04:13 minor nit: put = 0, =1, etc. to help further empha
fgorski 2016/10/12 20:44:09 done. Is that a new requirement? I don't remember
Mark P 2016/10/12 22:12:15 It's not a requirement, but it is a good practice.
+ LOADED, // Store is properly loaded and operational.
+ FAILED_LOADING, // Store initialization failed.
+ FAILED_RESET, // Resetting the store failed.
+ FAILED_OPERATION, // Store is still loaded, but individual operation
+ // experienced problems. (We want to get UMA if that ever
+ // happens.
+ // NOTE: always keep this entry at the end.
+ STORE_STATE_COUNT, // Number of values for UMA reporting.
};
// Statuses referring to actions taken on items in the stores.

Powered by Google App Engine
This is Rietveld 408576698