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

Issue 12334096: Regularize ownerships and lifecycle for storage monitor platform classes. (Closed)

Created:
7 years, 10 months ago by Greg Billock
Modified:
7 years, 9 months ago
CC:
chromium-reviews, sail+watch_chromium.org
Base URL:
http://git.chromium.org/chromium/src.git@master
Visibility:
Public.

Description

Regularize ownerships and lifecycle for storage monitor platform classes. This change regularizes the construction lifecycle of the StorageMonitor implementations so that they always exist for the construction of the Profile, but don't issue any notifications until after that construction is complete. This allows profile-based listeners to be sure they're synchronized with the monitor. It also regularizes ownership of all storage-monitor-related objects. The base platform-specific object is owned by the ChromeBrowserMain object, and owns all subsidiary platform-specific objects needed to monitor and/or deal with volumes of various types (i.e. MTP). R=vandebo@chromium.org BUG=None Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=187332 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=189078

Patch Set 1 #

Total comments: 4

Patch Set 2 : Merge to head #

Patch Set 3 : Mac include #

Patch Set 4 : in progress... changed to not require mtp manager in linux for tests. #

Total comments: 4

Patch Set 5 : Adding more lifecycle congruence across platforms. Move mtp manager out of CBM #

Patch Set 6 : Document lifecycle in storage_monitor.h #

Total comments: 8

Patch Set 7 : Check flags before MTP manager shutdown #

Patch Set 8 : Fix mac CF Ref check #

Total comments: 2

Patch Set 9 : Rebase #

Patch Set 10 : Rebase retry #

Patch Set 11 : Rebase #

Patch Set 12 : Remove windows pending VolumeMountWatcher pool management #

Total comments: 2

Patch Set 13 : Hand device manager shutdown to UI thread. #

Patch Set 14 : Rebase #

Patch Set 15 : Take out sequencing expectation of manager/observer #

Patch Set 16 : Fix comment name #

Unified diffs Side-by-side diffs Delta from patch set Stats (+108 lines, -58 lines) Patch
M chrome/browser/chrome_browser_main_linux.h View 1 2 3 4 5 6 7 8 9 10 2 chunks +0 lines, -7 lines 0 comments Download
M chrome/browser/chrome_browser_main_linux.cc View 1 2 3 4 5 6 7 8 9 10 5 chunks +5 lines, -29 lines 0 comments Download
M chrome/browser/chrome_browser_main_mac.h View 1 2 3 4 5 6 7 8 9 10 3 chunks +1 line, -3 lines 0 comments Download
M chrome/browser/chrome_browser_main_mac.mm View 1 2 3 4 5 6 7 8 9 10 11 2 chunks +6 lines, -7 lines 0 comments Download
M chrome/browser/chromeos/chrome_browser_main_chromeos.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 2 chunks +3 lines, -1 line 0 comments Download
M chrome/browser/storage_monitor/media_transfer_protocol_device_observer_linux.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 2 chunks +1 line, -2 lines 0 comments Download
M chrome/browser/storage_monitor/storage_monitor.h View 1 2 3 4 5 6 7 8 9 10 1 chunk +5 lines, -0 lines 0 comments Download
M chrome/browser/storage_monitor/storage_monitor_chromeos.h View 1 2 3 4 5 6 7 8 9 10 11 3 chunks +11 lines, -0 lines 0 comments Download
M chrome/browser/storage_monitor/storage_monitor_chromeos.cc View 1 2 3 4 5 6 7 8 9 10 11 12 3 chunks +23 lines, -3 lines 0 comments Download
M chrome/browser/storage_monitor/storage_monitor_linux.h View 1 2 3 4 5 6 7 8 9 10 11 2 chunks +5 lines, -0 lines 0 comments Download
M chrome/browser/storage_monitor/storage_monitor_linux.cc View 1 2 3 4 5 6 7 8 9 10 11 12 4 chunks +21 lines, -0 lines 0 comments Download
M chrome/browser/storage_monitor/storage_monitor_mac.h View 1 2 3 4 5 6 7 8 9 10 11 3 chunks +6 lines, -0 lines 0 comments Download
M chrome/browser/storage_monitor/storage_monitor_mac.mm View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 4 chunks +21 lines, -6 lines 0 comments Download

Messages

Total messages: 33 (0 generated)
Greg Billock
7 years, 10 months ago (2013-02-26 18:17:08 UTC) #1
Greg Billock
On 2013/02/26 18:17:08, Greg Billock wrote: This change as it stands introduces one significant sequencing ...
7 years, 10 months ago (2013-02-26 19:19:29 UTC) #2
vandebo (ex-Chrome)
On 2013/02/26 19:19:29, Greg Billock wrote: > On 2013/02/26 18:17:08, Greg Billock wrote: > > ...
7 years, 10 months ago (2013-02-26 23:07:44 UTC) #3
Greg Billock
On 2013/02/26 23:07:44, vandebo wrote: > On 2013/02/26 19:19:29, Greg Billock wrote: > > On ...
7 years, 9 months ago (2013-02-27 19:53:52 UTC) #4
Greg Billock
https://codereview.chromium.org/12334096/diff/1/chrome/browser/chrome_browser_main_mac.h File chrome/browser/chrome_browser_main_mac.h (left): https://codereview.chromium.org/12334096/diff/1/chrome/browser/chrome_browser_main_mac.h#oldcode12 chrome/browser/chrome_browser_main_mac.h:12: class ImageCaptureDeviceManager; On 2013/02/26 23:07:44, vandebo wrote: > Do ...
7 years, 9 months ago (2013-02-27 19:54:06 UTC) #5
Lei Zhang
I'd like to see all platforms behave consistently w.r.t. when they get initialized and when ...
7 years, 9 months ago (2013-02-28 02:14:43 UTC) #6
Greg Billock
Made all invocations consistent across platforms WRT profile and init behavior synchronization. There's a couple ...
7 years, 9 months ago (2013-02-28 22:35:37 UTC) #7
Greg Billock
On 2013/02/28 22:35:37, Greg Billock wrote: > Made all invocations consistent across platforms WRT profile ...
7 years, 9 months ago (2013-02-28 22:43:56 UTC) #8
Lei Zhang
lgtm https://codereview.chromium.org/12334096/diff/22008/chrome/browser/chrome_browser_main_linux.cc File chrome/browser/chrome_browser_main_linux.cc (right): https://codereview.chromium.org/12334096/diff/22008/chrome/browser/chrome_browser_main_linux.cc#newcode7 chrome/browser/chrome_browser_main_linux.cc:7: #include "base/message_loop_proxy.h" message_loop_proxy.h is no longer needed. chrome_switches.h ...
7 years, 9 months ago (2013-03-01 04:40:15 UTC) #9
Greg Billock
https://codereview.chromium.org/12334096/diff/22008/chrome/browser/chrome_browser_main_linux.cc File chrome/browser/chrome_browser_main_linux.cc (right): https://codereview.chromium.org/12334096/diff/22008/chrome/browser/chrome_browser_main_linux.cc#newcode7 chrome/browser/chrome_browser_main_linux.cc:7: #include "base/message_loop_proxy.h" On 2013/03/01 04:40:15, Lei Zhang wrote: > ...
7 years, 9 months ago (2013-03-01 18:00:50 UTC) #10
vandebo (ex-Chrome)
LGTM https://codereview.chromium.org/12334096/diff/18002/chrome/browser/storage_monitor/removable_device_notifications_mac.h File chrome/browser/storage_monitor/removable_device_notifications_mac.h (right): https://codereview.chromium.org/12334096/diff/18002/chrome/browser/storage_monitor/removable_device_notifications_mac.h#newcode35 chrome/browser/storage_monitor/removable_device_notifications_mac.h:35: void Init(); Should Init go on StorageMonitor, since ...
7 years, 9 months ago (2013-03-01 22:36:41 UTC) #11
Greg Billock
https://codereview.chromium.org/12334096/diff/18002/chrome/browser/storage_monitor/removable_device_notifications_mac.h File chrome/browser/storage_monitor/removable_device_notifications_mac.h (right): https://codereview.chromium.org/12334096/diff/18002/chrome/browser/storage_monitor/removable_device_notifications_mac.h#newcode35 chrome/browser/storage_monitor/removable_device_notifications_mac.h:35: void Init(); On 2013/03/01 22:36:41, vandebo wrote: > Should ...
7 years, 9 months ago (2013-03-01 23:08:03 UTC) #12
vandebo (ex-Chrome)
On 2013/03/01 23:08:03, Greg Billock wrote: > https://codereview.chromium.org/12334096/diff/18002/chrome/browser/storage_monitor/removable_device_notifications_mac.h > File chrome/browser/storage_monitor/removable_device_notifications_mac.h > (right): > > ...
7 years, 9 months ago (2013-03-01 23:13:01 UTC) #13
Greg Billock
On 2013/03/01 23:13:01, vandebo wrote: > On 2013/03/01 23:08:03, Greg Billock wrote: > > > ...
7 years, 9 months ago (2013-03-04 19:21:08 UTC) #14
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/gbillock@chromium.org/12334096/32004
7 years, 9 months ago (2013-03-05 20:00:23 UTC) #15
commit-bot: I haz the power
Failed to apply patch for chrome/browser/chrome_browser_main_linux.cc: While running patch -p1 --forward --force --no-backup-if-mismatch; patching file ...
7 years, 9 months ago (2013-03-05 20:00:29 UTC) #16
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/gbillock@chromium.org/12334096/36001
7 years, 9 months ago (2013-03-06 21:55:43 UTC) #17
commit-bot: I haz the power
Retried try job too often on win7_aura for step(s) browser_tests http://build.chromium.org/p/tryserver.chromium/buildstatus?builder=win7_aura&number=16996
7 years, 9 months ago (2013-03-07 02:22:58 UTC) #18
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/gbillock@chromium.org/12334096/36001
7 years, 9 months ago (2013-03-07 17:22:46 UTC) #19
commit-bot: I haz the power
Retried try job too often on win7_aura for step(s) browser_tests http://build.chromium.org/p/tryserver.chromium/buildstatus?builder=win7_aura&number=17275
7 years, 9 months ago (2013-03-07 21:48:13 UTC) #20
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/gbillock@chromium.org/12334096/60001
7 years, 9 months ago (2013-03-11 16:56:09 UTC) #21
commit-bot: I haz the power
Change committed as 187332
7 years, 9 months ago (2013-03-11 18:59:23 UTC) #22
Joao da Silva
Chrome doesn't shut down cleanly on Linux after this change, see inline. https://chromiumcodereview.appspot.com/12334096/diff/60001/chrome/browser/storage_monitor/storage_monitor_linux.cc File chrome/browser/storage_monitor/storage_monitor_linux.cc ...
7 years, 9 months ago (2013-03-12 14:15:23 UTC) #23
Greg Billock
Did you roll back? If not, I can do it. On Tue, Mar 12, 2013 ...
7 years, 9 months ago (2013-03-12 16:08:18 UTC) #24
Joao da Silva
On 2013/03/12 16:08:18, Greg Billock wrote: > Did you roll back? If not, I can ...
7 years, 9 months ago (2013-03-12 16:40:36 UTC) #25
Greg Billock
Done On Tue, Mar 12, 2013 at 9:40 AM, <joaodasilva@chromium.org> wrote: > On 2013/03/12 16:08:18, ...
7 years, 9 months ago (2013-03-12 16:49:33 UTC) #26
Greg Billock
https://codereview.chromium.org/12334096/diff/60001/chrome/browser/storage_monitor/storage_monitor_linux.cc File chrome/browser/storage_monitor/storage_monitor_linux.cc (right): https://codereview.chromium.org/12334096/diff/60001/chrome/browser/storage_monitor/storage_monitor_linux.cc#newcode297 chrome/browser/storage_monitor/storage_monitor_linux.cc:297: device::MediaTransferProtocolManager::Initialize(loop_proxy); Yes, we need to post back to the ...
7 years, 9 months ago (2013-03-12 21:15:29 UTC) #27
Greg Billock
On 2013/03/12 21:15:29, Greg Billock wrote: > https://codereview.chromium.org/12334096/diff/60001/chrome/browser/storage_monitor/storage_monitor_linux.cc > File chrome/browser/storage_monitor/storage_monitor_linux.cc (right): > > https://codereview.chromium.org/12334096/diff/60001/chrome/browser/storage_monitor/storage_monitor_linux.cc#newcode297 ...
7 years, 9 months ago (2013-03-12 21:17:11 UTC) #28
Lei Zhang
lgtm I'll probably refactor StorageMonitorLinux to separate the UI thread and FILE thread bits... when ...
7 years, 9 months ago (2013-03-18 09:37:51 UTC) #29
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/gbillock@chromium.org/12334096/85001
7 years, 9 months ago (2013-03-18 16:55:21 UTC) #30
commit-bot: I haz the power
Sorry for I got bad news for ya. Compile failed with a clobber build on ...
7 years, 9 months ago (2013-03-18 17:51:20 UTC) #31
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/gbillock@chromium.org/12334096/113001
7 years, 9 months ago (2013-03-19 16:14:40 UTC) #32
commit-bot: I haz the power
7 years, 9 months ago (2013-03-19 20:23:29 UTC) #33
Message was sent while issue was closed.
Change committed as 189078

Powered by Google App Engine
This is Rietveld 408576698