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

Side by Side Diff: components/offline_pages/offline_page_metadata_store_sql.h

Issue 2512073002: [Offline Pages] Removes two-step expiration related. (Closed)
Patch Set: Addressed comments. Created 4 years, 1 month 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 unified diff | Download patch
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef COMPONENTS_OFFLINE_PAGES_OFFLINE_PAGE_METADATA_STORE_SQL_H_ 5 #ifndef COMPONENTS_OFFLINE_PAGES_OFFLINE_PAGE_METADATA_STORE_SQL_H_
6 #define COMPONENTS_OFFLINE_PAGES_OFFLINE_PAGE_METADATA_STORE_SQL_H_ 6 #define COMPONENTS_OFFLINE_PAGES_OFFLINE_PAGE_METADATA_STORE_SQL_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <memory> 10 #include <memory>
(...skipping 17 matching lines...) Expand all
28 // which is implemented using a SQLite database. 28 // which is implemented using a SQLite database.
29 // 29 //
30 // This store has a history of schema updates in pretty much every release. 30 // This store has a history of schema updates in pretty much every release.
31 // Original schema was delivered in M52. Since then, the following changes 31 // Original schema was delivered in M52. Since then, the following changes
32 // happened: 32 // happened:
33 // * In M53 expiration_time was added, 33 // * In M53 expiration_time was added,
34 // * In M54 title was added, 34 // * In M54 title was added,
35 // * In M55 we dropped the following fields (never used): version, status, 35 // * In M55 we dropped the following fields (never used): version, status,
36 // offline_url, user_initiated. 36 // offline_url, user_initiated.
37 // * In M56 original_url was added. 37 // * In M56 original_url was added.
38 // * In M57 expiration_time was dropped. Existing expired pages would be
39 // removed when metadata consistency check happens.
fgorski 2016/11/22 00:02:59 Good! Probably worth commenting about that on the
romax 2016/11/23 23:32:02 Done.
38 // 40 //
39 // Here is a procedure to update the schema for this store: 41 // Here is a procedure to update the schema for this store:
40 // * Decide how to detect that the store is on a particular version, which 42 // * Decide how to detect that the store is on a particular version, which
41 // typically means that a certain field exists or is missing. This happens in 43 // typically means that a certain field exists or is missing. This happens in
42 // Upgrade section of |CreateSchema| 44 // Upgrade section of |CreateSchema|
43 // * Work out appropriate change and apply it to all existing upgrade paths. In 45 // * Work out appropriate change and apply it to all existing upgrade paths. In
44 // the interest of performing a single update of the store, it upgrades from a 46 // the interest of performing a single update of the store, it upgrades from a
45 // detected version to the current one. This means that when making a change, 47 // detected version to the current one. This means that when making a change,
46 // more than a single query may have to be updated (in case of fields being 48 // more than a single query may have to be updated (in case of fields being
47 // removed or needed to be initialized to a specific, non-default value). 49 // removed or needed to be initialized to a specific, non-default value).
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
94 StoreState state_; 96 StoreState state_;
95 97
96 base::WeakPtrFactory<OfflinePageMetadataStoreSQL> weak_ptr_factory_; 98 base::WeakPtrFactory<OfflinePageMetadataStoreSQL> weak_ptr_factory_;
97 99
98 DISALLOW_COPY_AND_ASSIGN(OfflinePageMetadataStoreSQL); 100 DISALLOW_COPY_AND_ASSIGN(OfflinePageMetadataStoreSQL);
99 }; 101 };
100 102
101 } // namespace offline_pages 103 } // namespace offline_pages
102 104
103 #endif // COMPONENTS_OFFLINE_PAGES_OFFLINE_PAGE_METADATA_STORE_SQL_H_ 105 #endif // COMPONENTS_OFFLINE_PAGES_OFFLINE_PAGE_METADATA_STORE_SQL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698