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

Issue 2851473002: predictors: Extract sql key-value tables into separate class. (Closed)

Created:
3 years, 7 months ago by alexilin
Modified:
3 years, 7 months ago
Reviewers:
Benoit L
CC:
chromium-reviews
Target Ref:
refs/heads/master
Project:
chromium
Visibility:
Public.

Description

predictors: Extract sql key-value tables into separate class. This is the first step of Glowplug Database refactoring. As a result we should get rid of boilerplate related to adding/removing tables from Glowplug. The next step will be providing users the direct access to tables instead of using Update{Resource,Redirect,etc.}Data wrappers. The code uses templates instead of google::protobuf::MessageLite for the type-safety. BUG=715525 Review-Url: https://codereview.chromium.org/2851473002 Cr-Commit-Position: refs/heads/master@{#468046} Committed: https://chromium.googlesource.com/chromium/src/+/6175b0a9f10d288f663f88c871c88ca3b5f0b9e8

Patch Set 1 #

Total comments: 15

Patch Set 2 : Untemplate some code. #

Total comments: 2

Patch Set 3 : Replace instead of delete and insert. #

Patch Set 4 : Rebase. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+215 lines, -235 lines) Patch
M chrome/browser/BUILD.gn View 1 2 3 1 chunk +2 lines, -0 lines 0 comments Download
A chrome/browser/predictors/glowplug_key_value_table.h View 1 2 1 chunk +102 lines, -0 lines 0 comments Download
A chrome/browser/predictors/glowplug_key_value_table.cc View 1 2 1 chunk +40 lines, -0 lines 0 comments Download
M chrome/browser/predictors/resource_prefetch_predictor_tables.h View 1 2 3 5 chunks +15 lines, -38 lines 0 comments Download
M chrome/browser/predictors/resource_prefetch_predictor_tables.cc View 1 2 3 15 chunks +56 lines, -197 lines 0 comments Download

Messages

Total messages: 13 (5 generated)
alexilin
Hi Benoit! Refactoring is coming!
3 years, 7 months ago (2017-04-27 12:04:10 UTC) #2
Benoit L
Yeah templates! Yeah less code! https://codereview.chromium.org/2851473002/diff/1/chrome/browser/predictors/glowplug_key_value_table.h File chrome/browser/predictors/glowplug_key_value_table.h (right): https://codereview.chromium.org/2851473002/diff/1/chrome/browser/predictors/glowplug_key_value_table.h#newcode21 chrome/browser/predictors/glowplug_key_value_table.h:21: void BindDataToStatement(const std::string& key, ...
3 years, 7 months ago (2017-04-27 15:49:03 UTC) #3
alexilin
https://codereview.chromium.org/2851473002/diff/1/chrome/browser/predictors/glowplug_key_value_table.h File chrome/browser/predictors/glowplug_key_value_table.h (right): https://codereview.chromium.org/2851473002/diff/1/chrome/browser/predictors/glowplug_key_value_table.h#newcode21 chrome/browser/predictors/glowplug_key_value_table.h:21: void BindDataToStatement(const std::string& key, On 2017/04/27 15:49:02, Benoit L ...
3 years, 7 months ago (2017-04-28 14:54:52 UTC) #4
Benoit L
lgtm https://codereview.chromium.org/2851473002/diff/1/chrome/browser/predictors/glowplug_key_value_table.h File chrome/browser/predictors/glowplug_key_value_table.h (right): https://codereview.chromium.org/2851473002/diff/1/chrome/browser/predictors/glowplug_key_value_table.h#newcode21 chrome/browser/predictors/glowplug_key_value_table.h:21: void BindDataToStatement(const std::string& key, On 2017/04/28 14:54:52, alexilin ...
3 years, 7 months ago (2017-04-28 15:12:35 UTC) #5
Benoit L
lgtm
3 years, 7 months ago (2017-04-28 15:12:36 UTC) #6
alexilin
https://codereview.chromium.org/2851473002/diff/1/chrome/browser/predictors/glowplug_key_value_table.h File chrome/browser/predictors/glowplug_key_value_table.h (right): https://codereview.chromium.org/2851473002/diff/1/chrome/browser/predictors/glowplug_key_value_table.h#newcode89 chrome/browser/predictors/glowplug_key_value_table.h:89: // Delete the older data from the table. On ...
3 years, 7 months ago (2017-04-28 16:27:26 UTC) #7
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/2851473002/60001
3 years, 7 months ago (2017-04-28 16:28:11 UTC) #10
commit-bot: I haz the power
3 years, 7 months ago (2017-04-28 17:34:55 UTC) #13
Message was sent while issue was closed.
Committed patchset #4 (id:60001) as
https://chromium.googlesource.com/chromium/src/+/6175b0a9f10d288f663f88c871c8...

Powered by Google App Engine
This is Rietveld 408576698