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

Issue 2954593002: History init: add metrics and skip migration. (Closed)

Created:
3 years, 6 months ago by brettw
Modified:
3 years, 6 months ago
CC:
chromium-reviews, asvitkine+watch_chromium.org
Target Ref:
refs/heads/master
Project:
chromium
Visibility:
Public.

Description

History init: add metrics and skip migration. Removes the migration code to history DB version 34. This version did a large migration of the URL table which can use several MB of disk storage. The suspicion is that this is causing more initialization failures for users with full devices. The change in version 34 is to add an AUTOINCREMENT tag on the primary key. This is required for some sync work that is in progress but is not complete, so skipping this migration step won't break any users. We will need to fix this before rolling out the new sync features. The 34 change also removed the favicon_id column. Because some databases may have the column and some won't, the code to copy to the in-memory database (which previously was implicit) now lists the columns to copy explicitly. Adds UMA logging for history database initialization failures, as well as versions for migration failures. Logging for the Sqlite error code for the various failure states may have been nice but would have required more plumbing and seemed impractical for now. There is one behavior change the error logging resulted in: errors migrating to version 22 were previously ignored but are now fatal. I believe continuing in this case was a mistake. This will only affect users migrating from an Android Chrome version prior to 2012, and failures here will likely be fatal anyway. BUG=734194, 736136 R=dtrainor@chromium.org, gangwu@chromium.org, mpearson@chromium.org, yzshen@chromium.org Review-Url: https://codereview.chromium.org/2954593002 . Cr-Commit-Position: refs/heads/master@{#481958} Committed: https://chromium.googlesource.com/chromium/src/+/ac7b23b2ea06f2826e7b2bca77475b2c11ce0973

Patch Set 1 #

Patch Set 2 : Fixes #

Patch Set 3 : Fixes #

Total comments: 1

Patch Set 4 : Comment typo #

Total comments: 2

Patch Set 5 : Copy column names #

Patch Set 6 : Explicit enum values #

Unified diffs Side-by-side diffs Delta from patch set Stats (+178 lines, -77 lines) Patch
M components/history/core/browser/history_backend.cc View 1 chunk +3 lines, -0 lines 0 comments Download
M components/history/core/browser/history_database.cc View 1 2 3 4 5 8 chunks +99 lines, -71 lines 0 comments Download
M components/history/core/browser/in_memory_database.cc View 1 2 3 4 1 chunk +16 lines, -1 line 0 comments Download
M components/history/core/browser/url_database.cc View 1 2 3 4 1 chunk +18 lines, -5 lines 0 comments Download
M tools/metrics/histograms/enums.xml View 1 chunk +9 lines, -0 lines 0 comments Download
M tools/metrics/histograms/histograms.xml View 1 2 3 3 chunks +33 lines, -0 lines 0 comments Download

Messages

Total messages: 35 (18 generated)
brettw
Fixes
3 years, 6 months ago (2017-06-23 00:09:20 UTC) #3
brettw
3 years, 6 months ago (2017-06-23 00:16:28 UTC) #5
brettw
Fixes
3 years, 6 months ago (2017-06-23 00:16:42 UTC) #6
brettw
3 years, 6 months ago (2017-06-23 00:17:00 UTC) #8
yzshen1
LGTM https://codereview.chromium.org/2954593002/diff/40001/tools/metrics/histograms/histograms.xml File tools/metrics/histograms/histograms.xml (right): https://codereview.chromium.org/2954593002/diff/40001/tools/metrics/histograms/histograms.xml#newcode24387 tools/metrics/histograms/histograms.xml:24387: + History database version from which which history ...
3 years, 6 months ago (2017-06-23 00:54:09 UTC) #12
brettw
Comment typo
3 years, 6 months ago (2017-06-23 00:56:04 UTC) #13
brettw
+mpearson TBR for histograms owners (this is blocking release, will address any feedback in a ...
3 years, 6 months ago (2017-06-23 00:57:52 UTC) #16
commit-bot: I haz the power
CQ is trying da patch. Follow status at: https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2954593002/60001
3 years, 6 months ago (2017-06-23 00:58:16 UTC) #19
David Trainor- moved to gerrit
lgtm
3 years, 6 months ago (2017-06-23 00:58:55 UTC) #21
commit-bot: I haz the power
Try jobs failed on following builders: linux_chromium_chromeos_ozone_rel_ng on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_chromeos_ozone_rel_ng/builds/413422)
3 years, 6 months ago (2017-06-23 01:44:09 UTC) #23
Mark P
metrics lgtm for the record, modulo one comment about labeling/comments in a .cc --mark https://codereview.chromium.org/2954593002/diff/60001/components/history/core/browser/history_database.cc ...
3 years, 6 months ago (2017-06-23 04:59:39 UTC) #24
Gang Wu
lgtm
3 years, 6 months ago (2017-06-23 16:35:26 UTC) #25
brettw
Copy column names
3 years, 6 months ago (2017-06-23 17:28:40 UTC) #26
brettw
Explicit enum values
3 years, 6 months ago (2017-06-23 17:35:24 UTC) #28
commit-bot: I haz the power
CQ is trying da patch. Follow status at: https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2954593002/100001
3 years, 6 months ago (2017-06-23 17:35:42 UTC) #31
brettw
https://codereview.chromium.org/2954593002/diff/60001/components/history/core/browser/history_database.cc File components/history/core/browser/history_database.cc (right): https://codereview.chromium.org/2954593002/diff/60001/components/history/core/browser/history_database.cc#newcode61 components/history/core/browser/history_database.cc:61: enum class InitStep { Done (I had to do ...
3 years, 6 months ago (2017-06-23 17:42:52 UTC) #32
brettw
3 years, 6 months ago (2017-06-23 18:13:37 UTC) #35
Message was sent while issue was closed.
Committed patchset #6 (id:100001) manually as
ac7b23b2ea06f2826e7b2bca77475b2c11ce0973 (presubmit successful).

Powered by Google App Engine
This is Rietveld 408576698