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

Issue 330473003: Offline blacklisting for SuggestionsService. (Closed)

Created:
6 years, 6 months ago by manzagop (departed)
Modified:
6 years, 6 months ago
CC:
chromium-reviews, skanuj+watch_chromium.org, melevin+watch_chromium.org, dhollowa+watch_chromium.org, dougw+watch_chromium.org, donnd+watch_chromium.org, dominich, jfweitz+watch_chromium.org, David Black, samarth+watch_chromium.org, kmadhusu+watch_chromium.org, Jered, Mike Lerman
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Visibility:
Public.

Description

Offline blacklisting for SuggestionsService. - Introduces a new pref to store a temporary local blacklist to. - Adds the BlacklistStore class, which is only meant to be a temporary repository to blacklist to until the user comes back online. It's not meant to store large blacklists. - Hooks up the BlacklistStore into SuggestionsService BUG=386241 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=279721

Patch Set 1 : Base version #

Total comments: 40

Patch Set 2 : Address Math's comments. #

Patch Set 3 : Add BlacklistFails unittest. #

Patch Set 4 : Add UMA logging of local blacklist #

Total comments: 34

Patch Set 5 : Address second round of comments. #

Total comments: 6

Patch Set 6 : Switch BlacklistStoreLogTest to UMAHistogramHelper - test still fails then succeeds. #

Patch Set 7 : Ensure StatisticsRecorder gets initialized in tests #

Patch Set 8 : Final merge. #

Total comments: 14

Patch Set 9 : Address Alexei's comments. #

Patch Set 10 : Move StatisticsRecorder Initialization from TestSuite to ContentTestSuiteBase #

Patch Set 11 : Rebase. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+827 lines, -105 lines) Patch
A chrome/browser/search/suggestions/blacklist_store.h View 1 2 3 4 1 chunk +71 lines, -0 lines 0 comments Download
A chrome/browser/search/suggestions/blacklist_store.cc View 1 2 3 4 5 6 7 8 1 chunk +175 lines, -0 lines 0 comments Download
A chrome/browser/search/suggestions/blacklist_store_unittest.cc View 1 2 3 4 5 6 7 8 1 chunk +149 lines, -0 lines 0 comments Download
M chrome/browser/search/suggestions/proto/suggestions.proto View 1 chunk +8 lines, -0 lines 0 comments Download
M chrome/browser/search/suggestions/suggestions_service.h View 1 2 3 4 5 6 7 8 9 10 5 chunks +45 lines, -10 lines 0 comments Download
M chrome/browser/search/suggestions/suggestions_service.cc View 1 2 3 4 5 6 7 8 9 10 13 chunks +159 lines, -57 lines 0 comments Download
M chrome/browser/search/suggestions/suggestions_service_factory.cc View 1 2 3 4 5 6 7 8 9 10 2 chunks +5 lines, -1 line 0 comments Download
M chrome/browser/search/suggestions/suggestions_service_unittest.cc View 1 2 3 4 5 6 7 8 9 10 18 chunks +189 lines, -33 lines 0 comments Download
M chrome/chrome_browser.gypi View 1 2 3 4 5 6 7 8 9 10 1 chunk +2 lines, -0 lines 0 comments Download
M chrome/chrome_tests_unit.gypi View 1 2 3 4 5 6 7 8 9 10 1 chunk +1 line, -0 lines 0 comments Download
M chrome/common/pref_names.h View 1 2 3 4 5 6 7 8 9 10 1 chunk +1 line, -0 lines 0 comments Download
M chrome/common/pref_names.cc View 1 2 3 4 5 6 7 8 9 10 1 chunk +4 lines, -0 lines 0 comments Download
M content/public/test/content_test_suite_base.cc View 1 2 3 4 5 6 7 8 9 2 chunks +6 lines, -0 lines 0 comments Download
M tools/metrics/histograms/histograms.xml View 3 chunks +12 lines, -4 lines 0 comments Download

Messages

Total messages: 38 (0 generated)
manzagop (departed)
Hey Mathieu, Can you have an early look? I'm trying to get this in before ...
6 years, 6 months ago (2014-06-16 15:20:50 UTC) #1
manzagop (departed)
6 years, 6 months ago (2014-06-16 21:05:38 UTC) #2
Mathieu
It's good that we have this. Overall comment: the logic is getting somewhat cumbersome i.e. ...
6 years, 6 months ago (2014-06-17 14:51:15 UTC) #3
manzagop (departed)
Addressed specific comments. Agreed about this class becoming too complex and that managing the blacklist ...
6 years, 6 months ago (2014-06-17 15:42:24 UTC) #4
manzagop (departed)
Actually, see my questions for two of those comments.
6 years, 6 months ago (2014-06-17 15:44:24 UTC) #5
Mathieu
Let me know when you want a full review (incl. tests?) https://codereview.chromium.org/330473003/diff/50001/chrome/browser/search/suggestions/suggestions_service.cc File chrome/browser/search/suggestions/suggestions_service.cc (right): ...
6 years, 6 months ago (2014-06-17 19:54:36 UTC) #6
manzagop (departed)
On 2014/06/17 19:54:36, Mathieu Perreault wrote: > Let me know when you want a full ...
6 years, 6 months ago (2014-06-17 20:25:47 UTC) #7
manzagop (departed)
Added the UMA logging of the local blacklist's size. PTAL.
6 years, 6 months ago (2014-06-17 22:09:47 UTC) #8
Mathieu
Adding asviktine@ for the histograms code (question in suggestions_service_unittest, too) Looking solid, more comments. Don't ...
6 years, 6 months ago (2014-06-18 13:56:23 UTC) #9
Alexei Svitkine (slow)
https://codereview.chromium.org/330473003/diff/110001/chrome/browser/search/suggestions/blacklist_store.cc File chrome/browser/search/suggestions/blacklist_store.cc (right): https://codereview.chromium.org/330473003/diff/110001/chrome/browser/search/suggestions/blacklist_store.cc#newcode46 chrome/browser/search/suggestions/blacklist_store.cc:46: HISTOGRAM_SPARSE_SLOWLY( UMA_HISTOGRAM_SPARSE_SLOWLY(), otherwise you're only recording a local one. ...
6 years, 6 months ago (2014-06-18 15:34:28 UTC) #10
Alexei Svitkine (slow)
Also, this is a large enough CL that it should have a corresponding crbug.
6 years, 6 months ago (2014-06-18 15:34:46 UTC) #11
Mathieu
https://codereview.chromium.org/330473003/diff/110001/chrome/browser/search/suggestions/blacklist_store.cc File chrome/browser/search/suggestions/blacklist_store.cc (right): https://codereview.chromium.org/330473003/diff/110001/chrome/browser/search/suggestions/blacklist_store.cc#newcode46 chrome/browser/search/suggestions/blacklist_store.cc:46: HISTOGRAM_SPARSE_SLOWLY( On 2014/06/18 15:34:28, Alexei Svitkine wrote: > UMA_HISTOGRAM_SPARSE_SLOWLY(), ...
6 years, 6 months ago (2014-06-18 15:48:06 UTC) #12
manzagop (departed)
Addressed comments. Still one issue with the Finch logging test though: BlacklistStoreTest.LogsBlacklistSize fails, then gets ...
6 years, 6 months ago (2014-06-18 18:44:55 UTC) #13
Mathieu
lgtm https://codereview.chromium.org/330473003/diff/130001/chrome/browser/search/suggestions/suggestions_service.cc File chrome/browser/search/suggestions/suggestions_service.cc (right): https://codereview.chromium.org/330473003/diff/130001/chrome/browser/search/suggestions/suggestions_service.cc#newcode129 chrome/browser/search/suggestions/suggestions_service.cc:129: extra line? https://codereview.chromium.org/330473003/diff/130001/chrome/browser/search/suggestions/suggestions_service.cc#newcode214 chrome/browser/search/suggestions/suggestions_service.cc:214: // Extract the blacklisted ...
6 years, 6 months ago (2014-06-18 19:04:54 UTC) #14
Alexei Svitkine (slow)
What's the test failure output? On Wed, Jun 18, 2014 at 3:04 PM, <mathp@chromium.org> wrote: ...
6 years, 6 months ago (2014-06-18 19:46:13 UTC) #15
Alexei Svitkine (slow)
Can you try following the helper class I suggest below and see if that helps ...
6 years, 6 months ago (2014-06-18 19:47:50 UTC) #16
manzagop (departed)
On 2014/06/18 19:46:13, Alexei Svitkine wrote: > What's the test failure output? As it's running ...
6 years, 6 months ago (2014-06-18 20:00:50 UTC) #17
manzagop (departed)
Test still "fails then succeeds" when using UMAHistogramHelper. If I replace UMA_HISTOGRAM_COUNTS_10000 with UMA_HISTOGRAM_SPARSE_SLOWLY the ...
6 years, 6 months ago (2014-06-19 14:36:56 UTC) #18
manzagop (departed)
Adding Pawel for base/test ownership. We figured out the issue. If the UMA logging macro ...
6 years, 6 months ago (2014-06-20 14:29:03 UTC) #19
Alexei Svitkine (slow)
lgtm % comments https://codereview.chromium.org/330473003/diff/230001/base/test/test_suite.cc File base/test/test_suite.cc (right): https://codereview.chromium.org/330473003/diff/230001/base/test/test_suite.cc#newcode285 base/test/test_suite.cc:285: // Record histograms, so we can ...
6 years, 6 months ago (2014-06-20 14:41:41 UTC) #20
manzagop (departed)
Adding Brett for base/test ownership, since it's late in PL-WAW for Pawel. Brett: I was ...
6 years, 6 months ago (2014-06-20 14:46:33 UTC) #21
manzagop (departed)
Addressed Alexei's comments, except one nit. https://codereview.chromium.org/330473003/diff/230001/base/test/test_suite.cc File base/test/test_suite.cc (right): https://codereview.chromium.org/330473003/diff/230001/base/test/test_suite.cc#newcode285 base/test/test_suite.cc:285: // Record histograms, ...
6 years, 6 months ago (2014-06-20 15:13:54 UTC) #22
Paweł Hajdan Jr.
base/test LGTM
6 years, 6 months ago (2014-06-20 16:22:59 UTC) #23
manzagop (departed)
Thanks for the quick replies everyone! On Fri, Jun 20, 2014 at 12:22 PM, <phajdan.jr@chromium.org> ...
6 years, 6 months ago (2014-06-20 16:26:51 UTC) #24
manzagop (departed)
The CQ bit was checked by manzagop@chromium.org
6 years, 6 months ago (2014-06-20 16:27:18 UTC) #25
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/manzagop@chromium.org/330473003/250001
6 years, 6 months ago (2014-06-20 16:28:59 UTC) #26
commit-bot: I haz the power
FYI, CQ is re-trying this CL (attempt #1). The failing builders are: android_dbg_triggered_tests on tryserver.chromium ...
6 years, 6 months ago (2014-06-20 23:58:33 UTC) #27
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 6 months ago (2014-06-21 00:30:32 UTC) #28
commit-bot: I haz the power
Try jobs failed on following builders: ios_dbg_simulator on tryserver.chromium (http://build.chromium.org/p/tryserver.chromium/builders/ios_dbg_simulator/builds/163698)
6 years, 6 months ago (2014-06-21 00:30:33 UTC) #29
manzagop (departed)
-brettw The change to TestSuite caused some tests in base/ to fail. Those tests create ...
6 years, 6 months ago (2014-06-25 12:23:20 UTC) #30
manzagop (departed)
The CQ bit was checked by manzagop@chromium.org
6 years, 6 months ago (2014-06-25 12:23:29 UTC) #31
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/manzagop@chromium.org/330473003/270001
6 years, 6 months ago (2014-06-25 12:23:50 UTC) #32
commit-bot: I haz the power
FYI, CQ is re-trying this CL (attempt #1). The failing builders are: android_dbg_triggered_tests on tryserver.chromium ...
6 years, 6 months ago (2014-06-25 12:27:04 UTC) #33
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 6 months ago (2014-06-25 12:28:35 UTC) #34
commit-bot: I haz the power
Try jobs failed on following builders: ios_rel_device_ninja on tryserver.chromium (http://build.chromium.org/p/tryserver.chromium/builders/ios_rel_device_ninja/builds/24823)
6 years, 6 months ago (2014-06-25 12:28:36 UTC) #35
manzagop (departed)
The CQ bit was checked by manzagop@chromium.org
6 years, 6 months ago (2014-06-25 13:49:32 UTC) #36
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/manzagop@chromium.org/330473003/290001
6 years, 6 months ago (2014-06-25 13:49:56 UTC) #37
commit-bot: I haz the power
6 years, 6 months ago (2014-06-25 16:07:44 UTC) #38
Message was sent while issue was closed.
Change committed as 279721

Powered by Google App Engine
This is Rietveld 408576698