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

Issue 830102 link

Starred by 2 users

Issue metadata

Status: Fixed
Owner:
Last visit > 30 days ago
Closed: Apr 2018
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Android
Pri: 1
Type: Bug



Sign in to add a comment

New consistency check for persistent pages for P2P sharing

Project Member Reported by romax@chromium.org, Apr 6 2018

Issue description

We need a new consistency check mechanism for persistent pages for P2P sharing feature, which should introduce a 'file missing' status for DB entries in case SDCard gets unmounted for file just gone for any reasons.
 
Project Member

Comment 1 by bugdroid1@chromium.org, Apr 21 2018

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

commit d9d4b3f878b1a4259072f5dbc7e091a473a38052
Author: Yafei Duan <romax@chromium.org>
Date: Sat Apr 21 00:13:15 2018

[Offline Pages] New persistent page consistency check

Introduces a new consistency check strategy for persistent pages. Since
persistent pages should be living in an external directory and exposed
to third party file explorers, we should not deleting any files.

Some more details:
- For all persistent pages, try to see if it still has its archive file
 - If not and the page has been missing the file for a while, delete the
   entry from DB and notify the system download manager about deletion;
   If it's newly discovered missing, set the file missing time in DB.
 - If the file is there and the page has been marked as missing file,
   remove the file missing time.
- The new persistent page consistency check will run together with the
  ClearStorageTask, scheduled by actions(GetAllPages or SavePage) and
  limited by a time threshold.

Bug:  830102 
Change-Id: Ie90d9fd988c642bdb6f598982f93e33642bd97ca
Reviewed-on: https://chromium-review.googlesource.com/1016015
Reviewed-by: Steven Holte <holte@chromium.org>
Reviewed-by: Peter Williamson <petewil@chromium.org>
Commit-Queue: Yafei Duan <romax@chromium.org>
Cr-Commit-Position: refs/heads/master@{#552526}
[modify] https://crrev.com/d9d4b3f878b1a4259072f5dbc7e091a473a38052/components/offline_pages/core/BUILD.gn
[modify] https://crrev.com/d9d4b3f878b1a4259072f5dbc7e091a473a38052/components/offline_pages/core/model/offline_page_item_generator.cc
[modify] https://crrev.com/d9d4b3f878b1a4259072f5dbc7e091a473a38052/components/offline_pages/core/model/offline_page_item_generator.h
[modify] https://crrev.com/d9d4b3f878b1a4259072f5dbc7e091a473a38052/components/offline_pages/core/model/offline_page_model_taskified.cc
[modify] https://crrev.com/d9d4b3f878b1a4259072f5dbc7e091a473a38052/components/offline_pages/core/model/offline_page_model_taskified.h
[modify] https://crrev.com/d9d4b3f878b1a4259072f5dbc7e091a473a38052/components/offline_pages/core/model/offline_page_model_taskified_unittest.cc
[add] https://crrev.com/d9d4b3f878b1a4259072f5dbc7e091a473a38052/components/offline_pages/core/model/persistent_page_consistency_check_task.cc
[add] https://crrev.com/d9d4b3f878b1a4259072f5dbc7e091a473a38052/components/offline_pages/core/model/persistent_page_consistency_check_task.h
[add] https://crrev.com/d9d4b3f878b1a4259072f5dbc7e091a473a38052/components/offline_pages/core/model/persistent_page_consistency_check_task_unittest.cc
[modify] https://crrev.com/d9d4b3f878b1a4259072f5dbc7e091a473a38052/components/offline_pages/core/model/startup_maintenance_task.cc
[modify] https://crrev.com/d9d4b3f878b1a4259072f5dbc7e091a473a38052/components/offline_pages/core/model/startup_maintenance_task.h
[modify] https://crrev.com/d9d4b3f878b1a4259072f5dbc7e091a473a38052/components/offline_pages/core/model/startup_maintenance_task_unittest.cc
[modify] https://crrev.com/d9d4b3f878b1a4259072f5dbc7e091a473a38052/tools/metrics/histograms/histograms.xml

Comment 2 by romax@chromium.org, Apr 23 2018

Cc: petewil@chromium.org
Labels: -Pri-3 Merge-Request-67 M-67 Pri-1

Comment 3 by cmasso@google.com, Apr 23 2018

Please confirm the fix works in canary

Comment 4 by romax@chromium.org, Apr 23 2018

Re #3: I just verified in Canary: 68.0.3404.0, and the CL for this issue worked correctly.

Thanks!
Project Member

Comment 5 by sheriffbot@chromium.org, Apr 24 2018

Labels: -Merge-Request-67 Merge-Approved-67 Hotlist-Merge-Approved
Your change meets the bar and is auto-approved for M67. Please go ahead and merge the CL to branch 3396 manually. Please contact milestone owner if you have questions.
Owners: cmasso@(Android), cmasso@(iOS), kbleicher@(ChromeOS), govind@(Desktop)

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
Project Member

Comment 6 by bugdroid1@chromium.org, Apr 24 2018

Labels: -merge-approved-67 merge-merged-3396
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/18384c8ad4db84f7373f11e9db07cc9340f988b1

commit 18384c8ad4db84f7373f11e9db07cc9340f988b1
Author: Yafei Duan <romax@chromium.org>
Date: Tue Apr 24 20:32:10 2018

[Offline Pages] New persistent page consistency check

Introduces a new consistency check strategy for persistent pages. Since
persistent pages should be living in an external directory and exposed
to third party file explorers, we should not deleting any files.

Some more details:
- For all persistent pages, try to see if it still has its archive file
 - If not and the page has been missing the file for a while, delete the
   entry from DB and notify the system download manager about deletion;
   If it's newly discovered missing, set the file missing time in DB.
 - If the file is there and the page has been marked as missing file,
   remove the file missing time.
- The new persistent page consistency check will run together with the
  ClearStorageTask, scheduled by actions(GetAllPages or SavePage) and
  limited by a time threshold.

Bug:  830102 
Change-Id: Ie90d9fd988c642bdb6f598982f93e33642bd97ca
Reviewed-on: https://chromium-review.googlesource.com/1016015
Reviewed-by: Steven Holte <holte@chromium.org>
Reviewed-by: Peter Williamson <petewil@chromium.org>
Commit-Queue: Yafei Duan <romax@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#552526}(cherry picked from commit d9d4b3f878b1a4259072f5dbc7e091a473a38052)
Reviewed-on: https://chromium-review.googlesource.com/1026610
Reviewed-by: Yafei Duan <romax@chromium.org>
Cr-Commit-Position: refs/branch-heads/3396@{#263}
Cr-Branched-From: 9ef2aa869bc7bc0c089e255d698cca6e47d6b038-refs/heads/master@{#550428}
[modify] https://crrev.com/18384c8ad4db84f7373f11e9db07cc9340f988b1/components/offline_pages/core/BUILD.gn
[modify] https://crrev.com/18384c8ad4db84f7373f11e9db07cc9340f988b1/components/offline_pages/core/model/offline_page_item_generator.cc
[modify] https://crrev.com/18384c8ad4db84f7373f11e9db07cc9340f988b1/components/offline_pages/core/model/offline_page_item_generator.h
[modify] https://crrev.com/18384c8ad4db84f7373f11e9db07cc9340f988b1/components/offline_pages/core/model/offline_page_model_taskified.cc
[modify] https://crrev.com/18384c8ad4db84f7373f11e9db07cc9340f988b1/components/offline_pages/core/model/offline_page_model_taskified.h
[modify] https://crrev.com/18384c8ad4db84f7373f11e9db07cc9340f988b1/components/offline_pages/core/model/offline_page_model_taskified_unittest.cc
[add] https://crrev.com/18384c8ad4db84f7373f11e9db07cc9340f988b1/components/offline_pages/core/model/persistent_page_consistency_check_task.cc
[add] https://crrev.com/18384c8ad4db84f7373f11e9db07cc9340f988b1/components/offline_pages/core/model/persistent_page_consistency_check_task.h
[add] https://crrev.com/18384c8ad4db84f7373f11e9db07cc9340f988b1/components/offline_pages/core/model/persistent_page_consistency_check_task_unittest.cc
[modify] https://crrev.com/18384c8ad4db84f7373f11e9db07cc9340f988b1/components/offline_pages/core/model/startup_maintenance_task.cc
[modify] https://crrev.com/18384c8ad4db84f7373f11e9db07cc9340f988b1/components/offline_pages/core/model/startup_maintenance_task.h
[modify] https://crrev.com/18384c8ad4db84f7373f11e9db07cc9340f988b1/components/offline_pages/core/model/startup_maintenance_task_unittest.cc
[modify] https://crrev.com/18384c8ad4db84f7373f11e9db07cc9340f988b1/tools/metrics/histograms/histograms.xml

Comment 7 by romax@chromium.org, Apr 24 2018

Status: Fixed (was: Started)

Sign in to add a comment