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

Issue 2239123002: dbus: Make Bus::GetManagedObjects skip unavailable services. (Closed)

Created:
4 years, 4 months ago by Daniel Erat
Modified:
4 years, 3 months ago
CC:
chromium-reviews
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

dbus: Make ObjectManager get objects after service is ready. Make dbus::ObjectManager automatically fetch managed objects after the remote service becomes available. Also remove Bus::GetManagedObjects(), which produces a large amount of log spam due to some services not yet being ready. (It was called by chromeos::DBusThreadManager and bluez::BluezDBusManager at startup.) BUG=636554 Committed: https://crrev.com/2ef7d0eda3fe8cb8a73c3ce977b8f1768cd32ece Cr-Commit-Position: refs/heads/master@{#417405}

Patch Set 1 #

Total comments: 1

Patch Set 2 : make ObjectManager defer getting objects until service is available #

Patch Set 3 : remove Bus::GetManagedObjects and BluezDBusManager's call to it #

Total comments: 2

Patch Set 4 : make initialization more serial #

Total comments: 3

Patch Set 5 : remove call to WaitForServiceToBeAvailable #

Unified diffs Side-by-side diffs Delta from patch set Stats (+40 lines, -66 lines) Patch
M chromeos/dbus/dbus_thread_manager.cc View 1 2 3 4 1 chunk +0 lines, -5 lines 0 comments Download
M dbus/bus.h View 1 2 1 chunk +0 lines, -6 lines 0 comments Download
M dbus/bus.cc View 1 2 1 chunk +0 lines, -7 lines 0 comments Download
M dbus/mock_object_manager.h View 1 2 1 chunk +0 lines, -1 line 0 comments Download
M dbus/object_manager.h View 1 2 3 4 2 chunks +7 lines, -9 lines 0 comments Download
M dbus/object_manager.cc View 1 2 3 4 2 chunks +33 lines, -33 lines 0 comments Download
M device/bluetooth/dbus/bluez_dbus_manager.cc View 1 2 1 chunk +0 lines, -5 lines 0 comments Download

Messages

Total messages: 49 (29 generated)
Daniel Erat
i still need to write tests for this, but i wanted to get your thoughts ...
4 years, 4 months ago (2016-08-11 22:51:56 UTC) #2
hashimoto
https://codereview.chromium.org/2239123002/diff/1/dbus/object_proxy.cc File dbus/object_proxy.cc (right): https://codereview.chromium.org/2239123002/diff/1/dbus/object_proxy.cc#newcode212 dbus/object_proxy.cc:212: return !service_name_owner_.empty(); This member should be accessed only on ...
4 years, 4 months ago (2016-08-15 07:23:22 UTC) #7
hashimoto
On 2016/08/11 22:51:56, Daniel Erat (OOO 8-12 to 8-22) wrote: > i still need to ...
4 years, 4 months ago (2016-08-15 07:24:56 UTC) #8
Daniel Erat
thanks for the comment! i've updated the approach (but haven't yet added tests). does this ...
4 years, 3 months ago (2016-08-31 16:46:22 UTC) #10
hashimoto
Thanks, this looks promising. https://codereview.chromium.org/2239123002/diff/40001/dbus/object_manager.cc File dbus/object_manager.cc (right): https://codereview.chromium.org/2239123002/diff/40001/dbus/object_manager.cc#newcode215 dbus/object_manager.cc:215: GetManagedObjects(); How about calling WaitForServiceToBeAvailable() ...
4 years, 3 months ago (2016-09-01 03:26:08 UTC) #18
Daniel Erat
https://codereview.chromium.org/2239123002/diff/40001/dbus/object_manager.cc File dbus/object_manager.cc (right): https://codereview.chromium.org/2239123002/diff/40001/dbus/object_manager.cc#newcode215 dbus/object_manager.cc:215: GetManagedObjects(); On 2016/09/01 03:26:07, hashimoto wrote: > How about ...
4 years, 3 months ago (2016-09-01 04:15:55 UTC) #19
Daniel Erat
https://codereview.chromium.org/2239123002/diff/60001/dbus/object_manager.h File dbus/object_manager.h (left): https://codereview.chromium.org/2239123002/diff/60001/dbus/object_manager.h#oldcode243 dbus/object_manager.h:243: void InitializeObjects(); i moved this into OnSetupMatchRuleAndFilterComplete since the ...
4 years, 3 months ago (2016-09-01 17:06:25 UTC) #21
hashimoto
Sorry for not noticing this before. With this code, GetManagedObjects() will get called twice by ...
4 years, 3 months ago (2016-09-02 08:33:07 UTC) #25
Daniel Erat
https://codereview.chromium.org/2239123002/diff/60001/dbus/object_manager.cc File dbus/object_manager.cc (right): https://codereview.chromium.org/2239123002/diff/60001/dbus/object_manager.cc#newcode242 dbus/object_manager.cc:242: weak_ptr_factory_.GetWeakPtr())); On 2016/09/02 08:33:06, hashimoto wrote: > You can ...
4 years, 3 months ago (2016-09-02 14:39:27 UTC) #26
Daniel Erat
thanks again for the suggestions. mind taking another look?
4 years, 3 months ago (2016-09-07 17:33:38 UTC) #27
hashimoto
thanks, lgtm
4 years, 3 months ago (2016-09-08 03:37:10 UTC) #32
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2239123002/80001
4 years, 3 months ago (2016-09-08 15:35:11 UTC) #34
commit-bot: I haz the power
Try jobs failed on following builders: chromium_presubmit on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/chromium_presubmit/builds/255593)
4 years, 3 months ago (2016-09-08 15:41:51 UTC) #36
Daniel Erat
rahul, please take a look at device/bluetooth/dbus. thanks!
4 years, 3 months ago (2016-09-08 15:50:33 UTC) #38
Rahul Chaturvedi
lgtm
4 years, 3 months ago (2016-09-08 20:02:47 UTC) #39
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2239123002/80001
4 years, 3 months ago (2016-09-08 20:16:16 UTC) #41
commit-bot: I haz the power
Try jobs failed on following builders: chromium_presubmit on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/chromium_presubmit/builds/255859)
4 years, 3 months ago (2016-09-08 20:18:22 UTC) #43
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2239123002/80001
4 years, 3 months ago (2016-09-08 20:51:13 UTC) #45
commit-bot: I haz the power
Committed patchset #5 (id:80001)
4 years, 3 months ago (2016-09-08 21:36:12 UTC) #47
commit-bot: I haz the power
4 years, 3 months ago (2016-09-08 21:39:53 UTC) #49
Message was sent while issue was closed.
Patchset 5 (id:??) landed as
https://crrev.com/2ef7d0eda3fe8cb8a73c3ce977b8f1768cd32ece
Cr-Commit-Position: refs/heads/master@{#417405}

Powered by Google App Engine
This is Rietveld 408576698