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

Issue 1871343002: Remove PermissionContext factories (Closed)

Created:
4 years, 8 months ago by raymes
Modified:
4 years, 8 months ago
CC:
chasej+watch_chromium.org, chrome-apps-syd-reviews_chromium.org, chromium-reviews, davemoore+watch_chromium.org, dkrahn+watch_chromium.org, feature-media-reviews_chromium.org, harkness+watch_chromium.org, iclelland+watch_chromium.org, jkarlin+watch_chromium.org, johnme+watch_chromium.org, lshang, mcasas+watch_chromium.org, mlamouri+watch-geolocation_chromium.org, mlamouri+watch-notifications_chromium.org, mlamouri+watch-permissions_chromium.org, Michael van Ouwerkerk, mvanouwerkerk+watch_chromium.org, oshima+watch_chromium.org, Peter Beverloo, posciak+watch_chromium.org, toyoshim+midi_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Remove PermissionContext factories Currently there is no real benefit to having each PermissionContext as a keyed service and it adds a lot of boilerplate. This CL moves PermissionContext construction into the PermissionManager keyed service instead. Committed: https://crrev.com/e3afee6b62380b5b09caf7513701f66d8964c6b6 Cr-Commit-Position: refs/heads/master@{#387843}

Patch Set 1 #

Patch Set 2 : #

Patch Set 3 : #

Total comments: 18

Patch Set 4 : #

Patch Set 5 : #

Total comments: 7

Patch Set 6 : #

Patch Set 7 : #

Total comments: 4

Patch Set 8 : #

Patch Set 9 : #

Unified diffs Side-by-side diffs Delta from patch set Stats (+201 lines, -1047 lines) Patch
M chrome/browser/android/tab_web_contents_delegate_android.cc View 1 chunk +0 lines, -1 line 0 comments Download
D chrome/browser/background_sync/background_sync_permission_context_factory.h View 1 chunk +0 lines, -35 lines 0 comments Download
D chrome/browser/background_sync/background_sync_permission_context_factory.cc View 1 chunk +0 lines, -32 lines 0 comments Download
M chrome/browser/chromeos/attestation/platform_verification_flow.cc View 1 2 3 4 5 6 4 chunks +11 lines, -11 lines 0 comments Download
D chrome/browser/geolocation/geolocation_permission_context_factory.h View 1 chunk +0 lines, -39 lines 0 comments Download
D chrome/browser/geolocation/geolocation_permission_context_factory.cc View 1 chunk +0 lines, -60 lines 0 comments Download
M chrome/browser/geolocation/geolocation_permission_context_unittest.cc View 1 2 3 2 chunks +6 lines, -3 lines 0 comments Download
M chrome/browser/guest_view/web_view/chrome_web_view_permission_helper_delegate.h View 1 2 3 2 chunks +2 lines, -2 lines 0 comments Download
M chrome/browser/guest_view/web_view/chrome_web_view_permission_helper_delegate.cc View 1 2 3 6 chunks +18 lines, -19 lines 0 comments Download
M chrome/browser/media/media_permission.cc View 1 2 3 4 5 2 chunks +5 lines, -2 lines 0 comments Download
D chrome/browser/media/media_stream_camera_permission_context_factory.h View 1 chunk +0 lines, -36 lines 0 comments Download
D chrome/browser/media/media_stream_camera_permission_context_factory.cc View 1 chunk +0 lines, -41 lines 0 comments Download
D chrome/browser/media/media_stream_mic_permission_context_factory.h View 1 chunk +0 lines, -36 lines 0 comments Download
D chrome/browser/media/media_stream_mic_permission_context_factory.cc View 1 chunk +0 lines, -39 lines 0 comments Download
D chrome/browser/media/midi_permission_context_factory.h View 1 chunk +0 lines, -34 lines 0 comments Download
D chrome/browser/media/midi_permission_context_factory.cc View 1 chunk +0 lines, -37 lines 0 comments Download
M chrome/browser/media/protected_media_identifier_permission_context.h View 2 chunks +1 line, -2 lines 0 comments Download
D chrome/browser/media/protected_media_identifier_permission_context_factory.h View 1 chunk +0 lines, -38 lines 0 comments Download
D chrome/browser/media/protected_media_identifier_permission_context_factory.cc View 1 chunk +0 lines, -45 lines 0 comments Download
D chrome/browser/notifications/notification_permission_context_factory.h View 1 chunk +0 lines, -35 lines 0 comments Download
D chrome/browser/notifications/notification_permission_context_factory.cc View 1 chunk +0 lines, -35 lines 0 comments Download
M chrome/browser/notifications/notifier_state_tracker_factory.cc View 2 chunks +2 lines, -2 lines 0 comments Download
M chrome/browser/notifications/platform_notification_service_browsertest.cc View 1 2 3 3 chunks +19 lines, -15 lines 0 comments Download
D chrome/browser/permissions/permission_context.h View 1 chunk +0 lines, -41 lines 0 comments Download
D chrome/browser/permissions/permission_context.cc View 1 chunk +0 lines, -95 lines 0 comments Download
D chrome/browser/permissions/permission_context_factory_base.h View 1 chunk +0 lines, -30 lines 0 comments Download
D chrome/browser/permissions/permission_context_factory_base.cc View 1 chunk +0 lines, -26 lines 0 comments Download
M chrome/browser/permissions/permission_manager.h View 1 2 3 4 5 5 chunks +21 lines, -0 lines 0 comments Download
M chrome/browser/permissions/permission_manager.cc View 1 2 3 4 5 10 chunks +76 lines, -13 lines 0 comments Download
M chrome/browser/permissions/permission_manager_factory.cc View 2 chunks +0 lines, -3 lines 0 comments Download
M chrome/browser/profiles/chrome_browser_main_extra_parts_profiles.cc View 4 chunks +1 line, -10 lines 0 comments Download
M chrome/browser/profiles/off_the_record_profile_impl.cc View 1 chunk +0 lines, -5 lines 0 comments Download
M chrome/browser/profiles/profile_impl.cc View 1 chunk +0 lines, -5 lines 0 comments Download
M chrome/browser/push_messaging/push_messaging_permission_context.h View 1 2 3 4 5 6 7 2 chunks +7 lines, -6 lines 0 comments Download
M chrome/browser/push_messaging/push_messaging_permission_context.cc View 1 2 3 4 5 6 7 8 5 chunks +15 lines, -20 lines 0 comments Download
D chrome/browser/push_messaging/push_messaging_permission_context_factory.h View 1 chunk +0 lines, -36 lines 0 comments Download
D chrome/browser/push_messaging/push_messaging_permission_context_factory.cc View 1 chunk +0 lines, -36 lines 0 comments Download
M chrome/browser/push_messaging/push_messaging_permission_context_unittest.cc View 1 2 3 1 chunk +8 lines, -4 lines 0 comments Download
M chrome/browser/push_messaging/push_messaging_service_unittest.cc View 3 chunks +9 lines, -25 lines 0 comments Download
D chrome/browser/storage/durable_storage_permission_context_factory.h View 1 chunk +0 lines, -35 lines 0 comments Download
D chrome/browser/storage/durable_storage_permission_context_factory.cc View 1 chunk +0 lines, -34 lines 0 comments Download
M chrome/chrome_browser.gypi View 10 chunks +0 lines, -24 lines 0 comments Download

Messages

Total messages: 50 (18 generated)
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1871343002/20001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1871343002/20001
4 years, 8 months ago (2016-04-11 02:45:17 UTC) #2
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: linux_chromium_compile_dbg_32_ng on tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_compile_dbg_32_ng/builds/185018)
4 years, 8 months ago (2016-04-11 02:56:06 UTC) #4
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1871343002/40001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1871343002/40001
4 years, 8 months ago (2016-04-11 03:41:06 UTC) #6
commit-bot: I haz the power
Dry run: This issue passed the CQ dry run.
4 years, 8 months ago (2016-04-11 04:22:44 UTC) #8
raymes
Hey Mounir, PTAL and let me know your thoughts. Thanks!
4 years, 8 months ago (2016-04-11 04:27:12 UTC) #11
mlamouri (slow - plz ping)
Thanks! This was among the low hanging fruits we needed to fix. Really great to ...
4 years, 8 months ago (2016-04-11 14:06:06 UTC) #12
raymes
Hey Mounir, PTAL. I managed to remove all the GetPermissionContext references in production code, except ...
4 years, 8 months ago (2016-04-12 07:44:54 UTC) #13
mlamouri (slow - plz ping)
still lgtm with comments applied https://codereview.chromium.org/1871343002/diff/40001/chrome/browser/permissions/permission_manager.h File chrome/browser/permissions/permission_manager.h (right): https://codereview.chromium.org/1871343002/diff/40001/chrome/browser/permissions/permission_manager.h#newcode102 chrome/browser/permissions/permission_manager.h:102: permission_contexts_; On 2016/04/12 at ...
4 years, 8 months ago (2016-04-12 11:36:40 UTC) #14
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1871343002/100001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1871343002/100001
4 years, 8 months ago (2016-04-13 00:22:31 UTC) #16
raymes
Thanks Mounir! https://codereview.chromium.org/1871343002/diff/40001/chrome/browser/permissions/permission_manager.h File chrome/browser/permissions/permission_manager.h (right): https://codereview.chromium.org/1871343002/diff/40001/chrome/browser/permissions/permission_manager.h#newcode102 chrome/browser/permissions/permission_manager.h:102: permission_contexts_; Unfortunately doing enum class PermissionType : ...
4 years, 8 months ago (2016-04-13 00:35:07 UTC) #17
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: chromeos_x86-generic_chromium_compile_only_ng on tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/chromeos_x86-generic_chromium_compile_only_ng/builds/120839) linux_chromium_gn_chromeos_rel on ...
4 years, 8 months ago (2016-04-13 00:35:13 UTC) #19
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1871343002/120001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1871343002/120001
4 years, 8 months ago (2016-04-13 00:40:00 UTC) #21
raymes
+OWNERS stevenjb: chrome/browser/chromeos/attestation/platform_verification_flow.cc chrome/browser/notifications/notification_permission_context_factory.cc chrome/browser/notifications/notification_permission_context_factory.h chrome/browser/notifications/notifier_state_tracker_factory.cc chrome/browser/notifications/platform_notification_service_browsertest.cc mlerman: chrome/browser/profiles/chrome_browser_main_extra_parts_profiles.cc chrome/browser/profiles/off_the_record_profile_impl.cc chrome/browser/profiles/profile_impl.cc jkarlin: chrome/browser/background_sync/background_sync_permission_context_factory.cc chrome/browser/background_sync/background_sync_permission_context_factory.h bauerb: ...
4 years, 8 months ago (2016-04-13 00:47:03 UTC) #23
dgrogan
durable lgtm
4 years, 8 months ago (2016-04-13 00:58:02 UTC) #24
lfg
guest_view lgtm
4 years, 8 months ago (2016-04-13 01:08:43 UTC) #25
commit-bot: I haz the power
Dry run: This issue passed the CQ dry run.
4 years, 8 months ago (2016-04-13 01:27:38 UTC) #27
mlamouri (slow - plz ping)
+jochen@ Jochen, can you rubberstamp the chrome/ changes resulting from the chrome/browser/permissions/ changes that I ...
4 years, 8 months ago (2016-04-13 13:06:32 UTC) #28
mlamouri (slow - plz ping)
(this is not Inbox, people don't get added magically :()
4 years, 8 months ago (2016-04-13 13:06:57 UTC) #30
Mike Lerman
profiles LGTM
4 years, 8 months ago (2016-04-13 13:09:31 UTC) #31
Michael van Ouwerkerk
https://codereview.chromium.org/1871343002/diff/120001/chrome/browser/push_messaging/push_messaging_permission_context.cc File chrome/browser/push_messaging/push_messaging_permission_context.cc (right): https://codereview.chromium.org/1871343002/diff/120001/chrome/browser/push_messaging/push_messaging_permission_context.cc#newcode124 chrome/browser/push_messaging/push_messaging_permission_context.cc:124: if (notification_status == blink::mojom::PermissionStatus::DENIED) { This is a behavioral ...
4 years, 8 months ago (2016-04-13 13:55:55 UTC) #32
Bernhard Bauer
c/b/android LGTM (feel free to TBR trivial changes like that if the overall change has ...
4 years, 8 months ago (2016-04-13 16:05:25 UTC) #33
xhwang
chrome/browser/media/ lgtm
4 years, 8 months ago (2016-04-13 16:08:20 UTC) #34
stevenjb
RS LGTM
4 years, 8 months ago (2016-04-13 16:22:06 UTC) #35
raymes
https://codereview.chromium.org/1871343002/diff/120001/chrome/browser/push_messaging/push_messaging_permission_context.cc File chrome/browser/push_messaging/push_messaging_permission_context.cc (right): https://codereview.chromium.org/1871343002/diff/120001/chrome/browser/push_messaging/push_messaging_permission_context.cc#newcode124 chrome/browser/push_messaging/push_messaging_permission_context.cc:124: if (notification_status == blink::mojom::PermissionStatus::DENIED) { On 2016/04/13 13:55:54, Michael ...
4 years, 8 months ago (2016-04-14 01:56:45 UTC) #36
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1871343002/140002 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1871343002/140002
4 years, 8 months ago (2016-04-14 01:57:29 UTC) #38
commit-bot: I haz the power
Dry run: This issue passed the CQ dry run.
4 years, 8 months ago (2016-04-14 02:47:25 UTC) #40
jkarlin
background_sync lgtm
4 years, 8 months ago (2016-04-14 11:44:13 UTC) #41
jochen (gone - plz use gerrit)
lgtm
4 years, 8 months ago (2016-04-14 13:22:33 UTC) #42
Michael van Ouwerkerk
lgtm
4 years, 8 months ago (2016-04-14 14:59:57 UTC) #43
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1871343002/140002 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1871343002/140002
4 years, 8 months ago (2016-04-18 00:47:20 UTC) #46
commit-bot: I haz the power
Committed patchset #9 (id:140002)
4 years, 8 months ago (2016-04-18 02:01:01 UTC) #48
commit-bot: I haz the power
4 years, 8 months ago (2016-04-18 02:02:07 UTC) #50
Message was sent while issue was closed.
Patchset 9 (id:??) landed as
https://crrev.com/e3afee6b62380b5b09caf7513701f66d8964c6b6
Cr-Commit-Position: refs/heads/master@{#387843}

Powered by Google App Engine
This is Rietveld 408576698