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

Issue 1090373003: Allow cross dependencies between BCKSF and BSKSF (Closed)

Created:
5 years, 8 months ago by sdefresne
Modified:
5 years, 8 months ago
Reviewers:
droger, Elliot Glaysher
CC:
chromium-reviews, darin-cc_chromium.org, jam
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Allow cross dependencies between BCKSF and BSKSF For incremental conversion of iOS code from BrowserContextKeyedServiceFactories to BrowserStateKeyedServiceFactories, iOS uses cross-dependencies between both types of factories. This CL had two virtual methods to KeyedServiceBaseFactory to convert a context to the correct type (content::BrowserContext or web::BrowserState) and back so that we can have BrowserStateKeyedServiceFactories registered into a BrowserContextDependencyManager (temporary). Implement the method in all derived classes and refactor the implementation of GetAssociatedPrefRegistry that no longer needs to be virtual. BUG=459020, 478763 Committed: https://crrev.com/8c1791c63d6a05455eb6c1413e01844496a119f4 Cr-Commit-Position: refs/heads/master@{#326782}

Patch Set 1 #

Patch Set 2 : Fix build issues #

Patch Set 3 : Fix dependencies and DCHECK in Get{Original,Underlying}ContextInternal #

Total comments: 6

Patch Set 4 : Address comments, simplify patch, rename methods #

Patch Set 5 : Remove wrapper methods #

Unified diffs Side-by-side diffs Delta from patch set Stats (+302 lines, -224 lines) Patch
M components/keyed_service.gypi View 1 2 3 4 chunks +5 lines, -6 lines 0 comments Download
M components/keyed_service/content/BUILD.gn View 1 2 1 chunk +1 line, -3 lines 0 comments Download
M components/keyed_service/content/browser_context_dependency_manager.h View 2 chunks +2 lines, -3 lines 0 comments Download
M components/keyed_service/content/browser_context_dependency_manager.cc View 2 chunks +6 lines, -4 lines 0 comments Download
M components/keyed_service/content/browser_context_keyed_base_factory.h View 1 2 3 2 chunks +1 line, -3 lines 0 comments Download
M components/keyed_service/content/browser_context_keyed_base_factory.cc View 1 2 3 2 chunks +0 lines, -13 lines 0 comments Download
M components/keyed_service/content/browser_context_keyed_service_factory.h View 1 2 3 2 chunks +1 line, -3 lines 0 comments Download
M components/keyed_service/content/browser_context_keyed_service_factory.cc View 1 2 3 2 chunks +0 lines, -11 lines 0 comments Download
M components/keyed_service/content/refcounted_browser_context_keyed_service_factory.h View 1 2 3 2 chunks +1 line, -3 lines 0 comments Download
M components/keyed_service/content/refcounted_browser_context_keyed_service_factory.cc View 1 2 3 2 chunks +0 lines, -13 lines 0 comments Download
M components/keyed_service/core/BUILD.gn View 1 2 1 chunk +2 lines, -0 lines 0 comments Download
M components/keyed_service/core/dependency_manager.h View 4 chunks +5 lines, -5 lines 0 comments Download
M components/keyed_service/core/dependency_manager.cc View 1 2 3 6 chunks +13 lines, -9 lines 0 comments Download
M components/keyed_service/core/keyed_service_base_factory.h View 1 2 3 4 4 chunks +57 lines, -8 lines 0 comments Download
M components/keyed_service/core/keyed_service_base_factory.cc View 1 2 3 4 5 chunks +34 lines, -9 lines 0 comments Download
M components/keyed_service/ios/DEPS View 1 2 1 chunk +0 lines, -1 line 0 comments Download
A components/keyed_service/ios/browser_state_context_converter.h View 1 2 3 1 chunk +55 lines, -0 lines 0 comments Download
A components/keyed_service/ios/browser_state_context_converter.cc View 1 2 3 1 chunk +28 lines, -0 lines 0 comments Download
M components/keyed_service/ios/browser_state_dependency_manager.h View 2 chunks +3 lines, -4 lines 0 comments Download
M components/keyed_service/ios/browser_state_dependency_manager.cc View 1 2 chunks +3 lines, -3 lines 0 comments Download
M components/keyed_service/ios/browser_state_helper.h View 1 2 3 1 chunk +0 lines, -32 lines 0 comments Download
M components/keyed_service/ios/browser_state_helper.cc View 1 2 3 1 chunk +0 lines, -50 lines 0 comments Download
M components/keyed_service/ios/browser_state_keyed_service_factory.h View 1 2 3 4 2 chunks +8 lines, -4 lines 0 comments Download
M components/keyed_service/ios/browser_state_keyed_service_factory.cc View 1 2 3 4 3 chunks +33 lines, -20 lines 0 comments Download
M components/keyed_service/ios/refcounted_browser_state_keyed_service_factory.h View 1 2 3 4 2 chunks +8 lines, -4 lines 0 comments Download
M components/keyed_service/ios/refcounted_browser_state_keyed_service_factory.cc View 1 2 3 4 3 chunks +34 lines, -11 lines 0 comments Download
M ios/chrome/browser/suggestions/suggestions_service_factory.h View 1 chunk +1 line, -1 line 0 comments Download
M ios/chrome/browser/suggestions/suggestions_service_factory.mm View 1 chunk +1 line, -1 line 0 comments Download

Messages

Total messages: 22 (9 generated)
sdefresne
erg: this is required to get cross dependencies (as I designed in https://docs.google.com/document/d/1HSHDxKiUui1io2odu5tkzddJZG21Fi7m0SGfnJj1soM/edit) to work ...
5 years, 8 months ago (2015-04-20 17:11:40 UTC) #2
droger
LGTM This CL makes the code more complex, but we really need this on iOS. ...
5 years, 8 months ago (2015-04-21 14:19:18 UTC) #5
Elliot Glaysher
https://codereview.chromium.org/1090373003/diff/60001/components/keyed_service/core/keyed_service_factory.cc File components/keyed_service/core/keyed_service_factory.cc (right): https://codereview.chromium.org/1090373003/diff/60001/components/keyed_service/core/keyed_service_factory.cc#newcode25 components/keyed_service/core/keyed_service_factory.cc:25: context = GetUnderlyingContext(context); This seems like it could be ...
5 years, 8 months ago (2015-04-21 17:54:32 UTC) #6
sdefresne
https://codereview.chromium.org/1090373003/diff/60001/components/keyed_service/core/keyed_service_factory.cc File components/keyed_service/core/keyed_service_factory.cc (right): https://codereview.chromium.org/1090373003/diff/60001/components/keyed_service/core/keyed_service_factory.cc#newcode25 components/keyed_service/core/keyed_service_factory.cc:25: context = GetUnderlyingContext(context); On 2015/04/21 17:54:32, Elliot Glaysher wrote: ...
5 years, 8 months ago (2015-04-22 08:53:16 UTC) #7
Elliot Glaysher
https://codereview.chromium.org/1090373003/diff/60001/components/keyed_service/core/keyed_service_factory.cc File components/keyed_service/core/keyed_service_factory.cc (right): https://codereview.chromium.org/1090373003/diff/60001/components/keyed_service/core/keyed_service_factory.cc#newcode25 components/keyed_service/core/keyed_service_factory.cc:25: context = GetUnderlyingContext(context); On 2015/04/22 08:53:15, sdefresne wrote: > ...
5 years, 8 months ago (2015-04-22 17:34:07 UTC) #8
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1090373003/120001
5 years, 8 months ago (2015-04-23 14:32:07 UTC) #11
sdefresne
erg, droger: PTAL
5 years, 8 months ago (2015-04-23 14:34:07 UTC) #13
droger
Still LGTM. I like the new names better. Now that only iOS implement this, we ...
5 years, 8 months ago (2015-04-23 15:33:41 UTC) #14
commit-bot: I haz the power
Dry run: This issue passed the CQ dry run.
5 years, 8 months ago (2015-04-23 15:42:49 UTC) #16
Elliot Glaysher
lgtm
5 years, 8 months ago (2015-04-23 17:14:45 UTC) #17
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1090373003/140001
5 years, 8 months ago (2015-04-24 11:30:55 UTC) #20
commit-bot: I haz the power
Committed patchset #5 (id:140001)
5 years, 8 months ago (2015-04-24 13:35:32 UTC) #21
commit-bot: I haz the power
5 years, 8 months ago (2015-04-24 13:36:23 UTC) #22
Message was sent while issue was closed.
Patchset 5 (id:??) landed as
https://crrev.com/8c1791c63d6a05455eb6c1413e01844496a119f4
Cr-Commit-Position: refs/heads/master@{#326782}

Powered by Google App Engine
This is Rietveld 408576698