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

Issue 10908065: Introduce a couple of abstract bases for WebDataService. (Closed)

Created:
8 years, 3 months ago by Jói
Modified:
8 years, 3 months ago
CC:
chromium-reviews, dhollowa+watch_chromium.org, Ilya Sherman, browser-components-watch_chromium.org, dyu1
Visibility:
Public.

Description

Introduce a couple of abstract bases for WebDataService. WebDataService is really a collection of different services that have a common initialization and some commonality e.g. how to cancel requests, and it's probably best that the interfaces reflect this logical split so that the implementation might some daybe tidied up. Starting this off with a WebDataServiceBase for the common bits, and an AutofillWebData for the Autofill-specific functionalities of WebDataService. Using these interfaces to break Autofill's concrete dependency on WebDataService. TBR=ben@chromium.org BUG=140037 Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=156567

Patch Set 1 #

Total comments: 7

Patch Set 2 : Merge to LKGR, remove unneeded {} #

Patch Set 3 : . #

Total comments: 12

Patch Set 4 : . #

Total comments: 40

Patch Set 5 : Respond to review comments. #

Patch Set 6 : Fix gypi file #

Total comments: 4

Patch Set 7 : Respond to comments #

Unified diffs Side-by-side diffs Delta from patch set Stats (+619 lines, -299 lines) Patch
M chrome/browser/api/DEPS View 1 chunk +3 lines, -0 lines 0 comments Download
A chrome/browser/api/webdata/autofill_web_data.h View 1 2 3 4 5 6 1 chunk +89 lines, -0 lines 0 comments Download
A chrome/browser/api/webdata/autofill_web_data_service.h View 1 2 3 4 5 6 1 chunk +28 lines, -0 lines 0 comments Download
A chrome/browser/api/webdata/web_data_results.h View 1 chunk +89 lines, -0 lines 0 comments Download
A chrome/browser/api/webdata/web_data_service_base.h View 1 2 3 4 5 6 1 chunk +30 lines, -0 lines 0 comments Download
A chrome/browser/api/webdata/web_data_service_consumer.h View 1 chunk +26 lines, -0 lines 0 comments Download
M chrome/browser/autofill/DEPS View 1 2 3 2 chunks +10 lines, -4 lines 0 comments Download
M chrome/browser/autofill/autocomplete_history_manager.h View 1 2 3 4 5 chunks +10 lines, -8 lines 0 comments Download
M chrome/browser/autofill/autocomplete_history_manager.cc View 1 2 3 7 chunks +12 lines, -14 lines 0 comments Download
M chrome/browser/autofill/autocomplete_history_manager_unittest.cc View 1 2 3 4 chunks +15 lines, -7 lines 0 comments Download
M chrome/browser/autofill/personal_data_manager.h View 1 2 3 4 5 chunks +13 lines, -11 lines 0 comments Download
M chrome/browser/autofill/personal_data_manager.cc View 1 2 3 4 5 6 28 chunks +78 lines, -79 lines 0 comments Download
M chrome/browser/autofill/personal_data_manager_unittest.cc View 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/sync/test/integration/autofill_helper.cc View 1 2 3 1 chunk +1 line, -0 lines 0 comments Download
A chrome/browser/webdata/autofill_web_data_service_impl.h View 1 2 3 4 5 6 1 chunk +53 lines, -0 lines 0 comments Download
A chrome/browser/webdata/autofill_web_data_service_impl.cc View 1 2 3 4 5 6 1 chunk +91 lines, -0 lines 0 comments Download
M chrome/browser/webdata/web_data_service.h View 1 2 3 4 5 6 9 chunks +35 lines, -172 lines 0 comments Download
M chrome/browser/webdata/web_data_service.cc View 1 2 3 4 5 6 3 chunks +6 lines, -3 lines 0 comments Download
M chrome/browser/webdata/web_data_service_factory.h View 1 2 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/webdata/web_data_service_factory.cc View 1 2 3 2 chunks +21 lines, -0 lines 0 comments Download
M chrome/chrome_browser.gypi View 1 2 3 4 5 2 chunks +7 lines, -0 lines 0 comments Download

Messages

Total messages: 38 (0 generated)
Jói
Erik, what do you think? Implicit in this approach is that ProfileKeyedService and RefcountedProfileKeyedService would ...
8 years, 3 months ago (2012-09-03 23:04:33 UTC) #1
Jói
I forgot to mention: This will of course go to a reviewer more familiar with ...
8 years, 3 months ago (2012-09-04 00:53:19 UTC) #2
Jói
+isherman to review WebDataService changes and the extracted API. Ilya, are you a good reviewer ...
8 years, 3 months ago (2012-09-04 01:03:44 UTC) #3
Ilya Sherman
I'm out on vacation until next week, so you might want to ask David Holloway ...
8 years, 3 months ago (2012-09-04 05:02:44 UTC) #4
dhollowa
http://codereview.chromium.org/10908065/diff/1/chrome/browser/webdata/web_data_service.h File chrome/browser/webdata/web_data_service.h (right): http://codereview.chromium.org/10908065/diff/1/chrome/browser/webdata/web_data_service.h#newcode105 chrome/browser/webdata/web_data_service.h:105: public AutofillWebData { Instead of splitting out just the ...
8 years, 3 months ago (2012-09-04 16:26:54 UTC) #5
Jói
On 2012/09/04 16:26:54, dhollowa wrote: > Instead of splitting out just the *interface* for AutofillWebData, ...
8 years, 3 months ago (2012-09-04 17:24:34 UTC) #6
erikwright (departed)
http://codereview.chromium.org/10908065/diff/1/chrome/browser/autofill/autocomplete_history_manager.cc File chrome/browser/autofill/autocomplete_history_manager.cc (right): http://codereview.chromium.org/10908065/diff/1/chrome/browser/autofill/autocomplete_history_manager.cc#newcode118 chrome/browser/autofill/autocomplete_history_manager.cc:118: web_data_service_ = WebDataServiceBase::ForProfile(profile_); Why go through WebDataServiceBase? Why not ...
8 years, 3 months ago (2012-09-04 17:43:50 UTC) #7
Jói
> Why go through WebDataServiceBase? Why not have > AutofillWebDataService::ForProfile and have the detail that ...
8 years, 3 months ago (2012-09-04 17:50:40 UTC) #8
erikwright (departed)
To my understanding, scoped_refptr<T> is constructable from scoped_refptr<U> if U is assignable to T. So ...
8 years, 3 months ago (2012-09-04 18:21:19 UTC) #9
erikwright (departed)
By "U is assignable to T" I meant U* is assignable to T*. On Tue, ...
8 years, 3 months ago (2012-09-04 18:22:36 UTC) #10
dhollowa
Autofill interface refactoring LGTM. http://codereview.chromium.org/10908065/diff/1/chrome/browser/autofill/personal_data_manager.cc File chrome/browser/autofill/personal_data_manager.cc (right): http://codereview.chromium.org/10908065/diff/1/chrome/browser/autofill/personal_data_manager.cc#newcode174 chrome/browser/autofill/personal_data_manager.cc:174: if (service) { nit: no ...
8 years, 3 months ago (2012-09-04 21:53:52 UTC) #11
Jói
http://codereview.chromium.org/10908065/diff/1/chrome/browser/autofill/autocomplete_history_manager.cc File chrome/browser/autofill/autocomplete_history_manager.cc (right): http://codereview.chromium.org/10908065/diff/1/chrome/browser/autofill/autocomplete_history_manager.cc#newcode118 chrome/browser/autofill/autocomplete_history_manager.cc:118: web_data_service_ = WebDataServiceBase::ForProfile(profile_); On 2012/09/04 17:43:50, erikwright wrote: > ...
8 years, 3 months ago (2012-09-06 01:17:27 UTC) #12
dhollowa
On 2012/09/06 01:17:27, Jói wrote: > http://codereview.chromium.org/10908065/diff/1/chrome/browser/autofill/autocomplete_history_manager.cc > File chrome/browser/autofill/autocomplete_history_manager.cc (right): > > http://codereview.chromium.org/10908065/diff/1/chrome/browser/autofill/autocomplete_history_manager.cc#newcode118 > ...
8 years, 3 months ago (2012-09-06 16:31:26 UTC) #13
Jói
Thanks for the suggestion. That would work great for now, but I believe it would ...
8 years, 3 months ago (2012-09-06 17:55:08 UTC) #14
erikwright (departed)
On 2012/09/06 16:31:26, dhollowa wrote: > On 2012/09/06 01:17:27, Jói wrote: > > > http://codereview.chromium.org/10908065/diff/1/chrome/browser/autofill/autocomplete_history_manager.cc ...
8 years, 3 months ago (2012-09-06 18:00:49 UTC) #15
erikwright (departed)
On 2012/09/06 17:55:08, Jói wrote: > Thanks for the suggestion. That would work great for ...
8 years, 3 months ago (2012-09-06 18:07:22 UTC) #16
dhollowa
> [...] > I'm of the impression that you guys are essentially describing the same ...
8 years, 3 months ago (2012-09-06 18:18:40 UTC) #17
Jói
Sounds like we are all in agreement, I think I will go with proposal (d) ...
8 years, 3 months ago (2012-09-06 18:22:22 UTC) #18
Jói
I uploaded a new patch with the approach discussed. It doesn't compile yet but I ...
8 years, 3 months ago (2012-09-06 22:53:01 UTC) #19
dhollowa
Very exciting! Great direction! http://codereview.chromium.org/10908065/diff/12002/chrome/browser/api/webdata/autofill_web_data.h File chrome/browser/api/webdata/autofill_web_data.h (right): http://codereview.chromium.org/10908065/diff/12002/chrome/browser/api/webdata/autofill_web_data.h#newcode94 chrome/browser/api/webdata/autofill_web_data.h:94: : public AutofillWebData, nit: ": ...
8 years, 3 months ago (2012-09-07 16:04:01 UTC) #20
dhollowa
http://codereview.chromium.org/10908065/diff/12002/chrome/browser/api/webdata/web_data_results.h File chrome/browser/api/webdata/web_data_results.h (right): http://codereview.chromium.org/10908065/diff/12002/chrome/browser/api/webdata/web_data_results.h#newcode11 chrome/browser/api/webdata/web_data_results.h:11: // Result types for WebDataService. Not for this CL, ...
8 years, 3 months ago (2012-09-07 16:10:40 UTC) #21
Jói
Erik: LGTY?
8 years, 3 months ago (2012-09-11 19:13:33 UTC) #22
erikwright (departed)
I don't understand why AutofillWebDataService needs to extend WebDataServiceBase. Reading through this CL, the only ...
8 years, 3 months ago (2012-09-11 20:49:06 UTC) #23
Jói
Erik, apologies: My still-jetlagged brain somehow forgot that this change was only half-ready; the patch ...
8 years, 3 months ago (2012-09-12 11:22:14 UTC) #24
erikwright (departed)
On Wed, Sep 12, 2012 at 7:21 AM, Jói Sigurðsson <joi@chromium.org> wrote: > Erik, apologies: ...
8 years, 3 months ago (2012-09-12 13:55:40 UTC) #25
Jói
> But is there a single client that needs to be able to interoperate with ...
8 years, 3 months ago (2012-09-12 14:21:16 UTC) #26
erikwright (departed)
On Wed, Sep 12, 2012 at 10:20 AM, Jói Sigurðsson <joi@chromium.org> wrote: > > But ...
8 years, 3 months ago (2012-09-12 15:15:55 UTC) #27
erikwright (departed)
On Wed, Sep 12, 2012 at 11:15 AM, Erik Wright <erikwright@chromium.org>wrote: > > > On ...
8 years, 3 months ago (2012-09-12 15:16:18 UTC) #28
Jói
Erik, please take a (hopefully final) look, seems to be complete and functional now. Cheers, ...
8 years, 3 months ago (2012-09-12 19:00:05 UTC) #29
erikwright (departed)
http://codereview.chromium.org/10908065/diff/15004/chrome/browser/api/webdata/autofill_web_data.h File chrome/browser/api/webdata/autofill_web_data.h (right): http://codereview.chromium.org/10908065/diff/15004/chrome/browser/api/webdata/autofill_web_data.h#newcode13 chrome/browser/api/webdata/autofill_web_data.h:13: #include "chrome/browser/api/webdata/web_data_service_consumer.h" forward-decl? http://codereview.chromium.org/10908065/diff/15004/chrome/browser/api/webdata/autofill_web_data.h#newcode93 chrome/browser/api/webdata/autofill_web_data.h:93: class AutofillWebDataService It may ...
8 years, 3 months ago (2012-09-13 01:45:11 UTC) #30
Jói
Thanks for the thorough review Erik. I've uploaded a patch to address your comments. Cheers, ...
8 years, 3 months ago (2012-09-13 12:34:50 UTC) #31
erikwright (departed)
LGTM. http://codereview.chromium.org/10908065/diff/15004/chrome/browser/api/webdata/web_data_service_base.h File chrome/browser/api/webdata/web_data_service_base.h (right): http://codereview.chromium.org/10908065/diff/15004/chrome/browser/api/webdata/web_data_service_base.h#newcode26 chrome/browser/api/webdata/web_data_service_base.h:26: virtual WebDataServiceBase* GetNotificationSource() = 0; On 2012/09/13 12:34:50, ...
8 years, 3 months ago (2012-09-13 13:28:10 UTC) #32
dhollowa
LGTM.
8 years, 3 months ago (2012-09-13 14:44:17 UTC) #33
Jói
Thanks, I decided to switch to NotificationSource as you had suggested. I'm passing it by ...
8 years, 3 months ago (2012-09-13 14:48:52 UTC) #34
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/joi@chromium.org/10908065/6021
8 years, 3 months ago (2012-09-13 14:49:15 UTC) #35
commit-bot: I haz the power
Presubmit check for 10908065-6021 failed and returned exit status 1. Running presubmit commit checks ...
8 years, 3 months ago (2012-09-13 14:49:25 UTC) #36
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/joi@chromium.org/10908065/6021
8 years, 3 months ago (2012-09-13 14:52:18 UTC) #37
commit-bot: I haz the power
8 years, 3 months ago (2012-09-13 17:06:21 UTC) #38
Change committed as 156567

Powered by Google App Engine
This is Rietveld 408576698