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

Issue 2019333008: [Offline Pages] Fix crash due to table inconsistency. (Closed)

Created:
4 years, 6 months ago by romax
Modified:
4 years, 6 months ago
Reviewers:
jianli, fgorski
CC:
chromium-reviews, romax+watch_chromium.org, fgorski+watch_chromium.org, dewittj+watch_chromium.org, petewil+watch_chromium.org, chili+watch_chromium.org, dimich+watch_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

[Offline Pages] Fix crash due to table inconsistency. Adding logic to add a column if there wasn't one when upgrading. BUG=615549 Committed: https://crrev.com/161706f2098084c856c3a9537a3e072aa5fd852f Cr-Commit-Position: refs/heads/master@{#397872}

Patch Set 1 #

Total comments: 2

Patch Set 2 : Replacing old table if schema is changed. And regression test. #

Patch Set 3 : fixing build. #

Patch Set 4 : fix win build #

Total comments: 11

Patch Set 5 : comments from fgorski@ #

Total comments: 17

Patch Set 6 : comments from jianli@ #

Unified diffs Side-by-side diffs Delta from patch set Stats (+163 lines, -10 lines) Patch
M components/offline_pages/BUILD.gn View 1 2 3 4 1 chunk +1 line, -0 lines 0 comments Download
M components/offline_pages/offline_page_metadata_store_impl_unittest.cc View 1 2 3 4 5 9 chunks +125 lines, -5 lines 0 comments Download
M components/offline_pages/offline_page_metadata_store_sql.cc View 1 2 3 4 5 3 chunks +37 lines, -5 lines 0 comments Download

Messages

Total messages: 17 (5 generated)
romax
PTAL and please let me know how I can repro/verify this crash is fixed...
4 years, 6 months ago (2016-06-01 01:16:23 UTC) #2
fgorski
romax@, I think this code will put the column at the end and it would ...
4 years, 6 months ago (2016-06-01 16:52:04 UTC) #4
jianli
Please make sure you test if the crash is fixed. Also add a test if ...
4 years, 6 months ago (2016-06-01 20:54:37 UTC) #5
romax
Updating, will recreate the table if columns are inconsistent, also adding a regression test. There ...
4 years, 6 months ago (2016-06-03 17:29:29 UTC) #6
fgorski
https://codereview.chromium.org/2019333008/diff/60001/components/offline_pages/offline_page_metadata_store_impl_unittest.cc File components/offline_pages/offline_page_metadata_store_impl_unittest.cc (right): https://codereview.chromium.org/2019333008/diff/60001/components/offline_pages/offline_page_metadata_store_impl_unittest.cc#newcode39 components/offline_pages/offline_page_metadata_store_impl_unittest.cc:39: // TODO(romax): move it to sql_unittests. good point. Another ...
4 years, 6 months ago (2016-06-03 18:17:16 UTC) #7
romax
Addressed comments from Filip, PTAL. https://codereview.chromium.org/2019333008/diff/60001/components/offline_pages/offline_page_metadata_store_impl_unittest.cc File components/offline_pages/offline_page_metadata_store_impl_unittest.cc (right): https://codereview.chromium.org/2019333008/diff/60001/components/offline_pages/offline_page_metadata_store_impl_unittest.cc#newcode39 components/offline_pages/offline_page_metadata_store_impl_unittest.cc:39: // TODO(romax): move it ...
4 years, 6 months ago (2016-06-03 19:36:22 UTC) #8
fgorski
lgtm This implementation works and I like it. I made an extra comment about table ...
4 years, 6 months ago (2016-06-03 20:04:17 UTC) #9
jianli
lgtm https://codereview.chromium.org/2019333008/diff/80001/components/offline_pages/offline_page_metadata_store_impl_unittest.cc File components/offline_pages/offline_page_metadata_store_impl_unittest.cc (right): https://codereview.chromium.org/2019333008/diff/80001/components/offline_pages/offline_page_metadata_store_impl_unittest.cc#newcode29 components/offline_pages/offline_page_metadata_store_impl_unittest.cc:29: #define OFFLINE_PAGES_TABLE_V1 "offlinepages_v1" On 2016/06/03 20:04:17, fgorski wrote: ...
4 years, 6 months ago (2016-06-03 21:12:19 UTC) #10
romax
addressed comments from jianli@, will commit once all try bots passed. https://codereview.chromium.org/2019333008/diff/80001/components/offline_pages/offline_page_metadata_store_impl_unittest.cc File components/offline_pages/offline_page_metadata_store_impl_unittest.cc (right): ...
4 years, 6 months ago (2016-06-03 23:11:40 UTC) #11
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/2019333008/100001
4 years, 6 months ago (2016-06-04 00:52:26 UTC) #14
commit-bot: I haz the power
Committed patchset #6 (id:100001)
4 years, 6 months ago (2016-06-04 00:57:08 UTC) #15
commit-bot: I haz the power
4 years, 6 months ago (2016-06-04 00:58:45 UTC) #17
Message was sent while issue was closed.
Patchset 6 (id:??) landed as
https://crrev.com/161706f2098084c856c3a9537a3e072aa5fd852f
Cr-Commit-Position: refs/heads/master@{#397872}

Powered by Google App Engine
This is Rietveld 408576698