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

Issue 2498743002: Mojo: introducing a thread safe interface pointer. (Closed)

Created:
4 years, 1 month ago by Jay Civelli
Modified:
4 years, 1 month ago
CC:
Aaron Boodman, abarth-chromium, chromium-reviews, darin (slow to review), qsr+mojo_chromium.org, viettrungluu+watch_chromium.org, yzshen+watch_chromium.org
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Creating a thread safe interface pointer that is tied to an actual InterfacePtr and forwards message from interface calls to the InterfacePtr thread and forwards back response messages to the calling thread. BUG=664628 TEST=InterfacePtrTest.TestThreadSafeInterfacePointer Committed: https://crrev.com/64c7ea9ccda1354968015f4979135760627435e1 Cr-Commit-Position: refs/heads/master@{#432387}

Patch Set 1 #

Patch Set 2 : Clean-up #

Total comments: 8

Patch Set 3 : Addressed comments. #

Patch Set 4 : Sync + clean-up #

Patch Set 5 : Fix Android compile #

Total comments: 16

Patch Set 6 : Addressed @yzshen1 comments. #

Total comments: 2

Patch Set 7 : Mojo: introducing a thread safe interface pointer. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+242 lines, -17 lines) Patch
M mojo/public/cpp/bindings/lib/associated_interface_ptr_state.h View 1 2 1 chunk +1 line, -2 lines 0 comments Download
M mojo/public/cpp/bindings/lib/interface_ptr_state.h View 1 2 3 6 chunks +28 lines, -5 lines 0 comments Download
M mojo/public/cpp/bindings/tests/interface_ptr_unittest.cc View 1 2 3 2 chunks +42 lines, -0 lines 0 comments Download
A mojo/public/cpp/bindings/thread_safe_interface_ptr.h View 1 2 3 4 5 1 chunk +154 lines, -0 lines 0 comments Download
M mojo/public/tools/bindings/generators/cpp_templates/interface_definition.tmpl View 1 2 3 4 5 6 3 chunks +10 lines, -6 lines 0 comments Download
M mojo/public/tools/bindings/generators/cpp_templates/interface_proxy_declaration.tmpl View 1 2 3 4 5 1 chunk +4 lines, -4 lines 0 comments Download
M mojo/public/tools/bindings/generators/cpp_templates/module.h.tmpl View 1 2 3 2 chunks +3 lines, -0 lines 0 comments Download

Messages

Total messages: 49 (21 generated)
Jay Civelli
4 years, 1 month ago (2016-11-11 21:35:25 UTC) #3
Ken Rockot(use gerrit already)
I don't have time to look at this today (OOO) but I already know the ...
4 years, 1 month ago (2016-11-11 21:36:53 UTC) #4
yzshen1
https://codereview.chromium.org/2498743002/diff/20001/mojo/public/cpp/bindings/lib/interface_ptr_state.h File mojo/public/cpp/bindings/lib/interface_ptr_state.h (right): https://codereview.chromium.org/2498743002/diff/20001/mojo/public/cpp/bindings/lib/interface_ptr_state.h#newcode336 mojo/public/cpp/bindings/lib/interface_ptr_state.h:336: scoped_refptr<ThreadSafeInterfacePtr<Interface>> GetThreadSafePtr() { One thing that seems a little ...
4 years, 1 month ago (2016-11-11 22:32:10 UTC) #5
darin (slow to review)
https://codereview.chromium.org/2498743002/diff/20001/mojo/public/cpp/bindings/thread_safe_interface_ptr.h File mojo/public/cpp/bindings/thread_safe_interface_ptr.h (right): https://codereview.chromium.org/2498743002/diff/20001/mojo/public/cpp/bindings/thread_safe_interface_ptr.h#newcode33 mojo/public/cpp/bindings/thread_safe_interface_ptr.h:33: public base::RefCountedThreadSafe<ThreadSafeInterfacePtr<Interface>> { Does this class need to be ...
4 years, 1 month ago (2016-11-12 04:09:23 UTC) #11
Ken Rockot(use gerrit already)
On 2016/11/12 at 04:09:23, darin wrote: > https://codereview.chromium.org/2498743002/diff/20001/mojo/public/cpp/bindings/thread_safe_interface_ptr.h > File mojo/public/cpp/bindings/thread_safe_interface_ptr.h (right): > > https://codereview.chromium.org/2498743002/diff/20001/mojo/public/cpp/bindings/thread_safe_interface_ptr.h#newcode33 ...
4 years, 1 month ago (2016-11-12 09:01:23 UTC) #12
Jay Civelli
On 2016/11/12 09:01:23, Ken Rockot wrote: > On 2016/11/12 at 04:09:23, darin wrote: > > ...
4 years, 1 month ago (2016-11-12 16:56:22 UTC) #13
Ken Rockot(use gerrit already)
On Nov 12, 2016 8:56 AM, <jcivelli@chromium.org> wrote: > > On 2016/11/12 09:01:23, Ken Rockot ...
4 years, 1 month ago (2016-11-12 19:06:27 UTC) #14
yzshen1
On 2016/11/12 16:56:22, Jay Civelli wrote: > On 2016/11/12 09:01:23, Ken Rockot wrote: > > ...
4 years, 1 month ago (2016-11-13 02:29:18 UTC) #15
Ken Rockot(use gerrit already)
On 2016/11/13 at 02:29:18, yzshen wrote: > On 2016/11/12 16:56:22, Jay Civelli wrote: > > ...
4 years, 1 month ago (2016-11-13 02:38:59 UTC) #16
yzshen1
On 2016/11/13 02:38:59, Ken Rockot wrote: > On 2016/11/13 at 02:29:18, yzshen wrote: > > ...
4 years, 1 month ago (2016-11-14 17:36:27 UTC) #17
Ken Rockot(use gerrit already)
I am not following why (1) would not be thread-safe. On Mon, Nov 14, 2016 ...
4 years, 1 month ago (2016-11-14 18:11:51 UTC) #18
yzshen1
On 2016/11/14 18:11:51, Ken Rockot wrote: > I am not following why (1) would not ...
4 years, 1 month ago (2016-11-14 18:25:40 UTC) #19
Jay Civelli
I think the concern is that the ProxyType is not reentrant. After a chat with ...
4 years, 1 month ago (2016-11-14 18:26:35 UTC) #20
Ken Rockot(use gerrit already)
Oh, sorry, I didn't actually look at the CL in deatil :). when we originally ...
4 years, 1 month ago (2016-11-14 18:30:19 UTC) #21
Jay Civelli
There is also the group_controller we'd have to take care of. We could go either ...
4 years, 1 month ago (2016-11-14 18:42:17 UTC) #22
Jay Civelli
Sorry the group controller is part of the serialization context, but I believe there were ...
4 years, 1 month ago (2016-11-14 18:43:56 UTC) #23
Jay Civelli
https://codereview.chromium.org/2498743002/diff/20001/mojo/public/cpp/bindings/lib/interface_ptr_state.h File mojo/public/cpp/bindings/lib/interface_ptr_state.h (right): https://codereview.chromium.org/2498743002/diff/20001/mojo/public/cpp/bindings/lib/interface_ptr_state.h#newcode336 mojo/public/cpp/bindings/lib/interface_ptr_state.h:336: scoped_refptr<ThreadSafeInterfacePtr<Interface>> GetThreadSafePtr() { On 2016/11/11 22:32:10, yzshen1 wrote: > ...
4 years, 1 month ago (2016-11-15 05:02:30 UTC) #24
yzshen1
https://codereview.chromium.org/2498743002/diff/80001/mojo/public/cpp/bindings/lib/interface_ptr_state.h File mojo/public/cpp/bindings/lib/interface_ptr_state.h (right): https://codereview.chromium.org/2498743002/diff/80001/mojo/public/cpp/bindings/lib/interface_ptr_state.h#newcode410 mojo/public/cpp/bindings/lib/interface_ptr_state.h:410: base::WeakPtrFactory<InterfacePtrState> weak_ptr_factory_; It is not needed in the majority ...
4 years, 1 month ago (2016-11-15 18:53:46 UTC) #31
Jay Civelli
https://codereview.chromium.org/2498743002/diff/80001/mojo/public/cpp/bindings/lib/interface_ptr_state.h File mojo/public/cpp/bindings/lib/interface_ptr_state.h (right): https://codereview.chromium.org/2498743002/diff/80001/mojo/public/cpp/bindings/lib/interface_ptr_state.h#newcode410 mojo/public/cpp/bindings/lib/interface_ptr_state.h:410: base::WeakPtrFactory<InterfacePtrState> weak_ptr_factory_; On 2016/11/15 18:53:46, yzshen1 wrote: > It ...
4 years, 1 month ago (2016-11-15 19:36:38 UTC) #32
yzshen1
LGTM with one nit Thanks! https://codereview.chromium.org/2498743002/diff/80001/mojo/public/cpp/bindings/lib/interface_ptr_state.h File mojo/public/cpp/bindings/lib/interface_ptr_state.h (right): https://codereview.chromium.org/2498743002/diff/80001/mojo/public/cpp/bindings/lib/interface_ptr_state.h#newcode410 mojo/public/cpp/bindings/lib/interface_ptr_state.h:410: base::WeakPtrFactory<InterfacePtrState> weak_ptr_factory_; On 2016/11/15 ...
4 years, 1 month ago (2016-11-15 20:26:15 UTC) #33
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/2498743002/120001
4 years, 1 month ago (2016-11-15 20:34:02 UTC) #36
Jay Civelli
https://codereview.chromium.org/2498743002/diff/100001/mojo/public/tools/bindings/generators/cpp_templates/interface_definition.tmpl File mojo/public/tools/bindings/generators/cpp_templates/interface_definition.tmpl (right): https://codereview.chromium.org/2498743002/diff/100001/mojo/public/tools/bindings/generators/cpp_templates/interface_definition.tmpl#newcode205 mojo/public/tools/bindings/generators/cpp_templates/interface_definition.tmpl:205: callback, group_controller_.get()); On 2016/11/15 20:26:15, yzshen1 wrote: > remove ...
4 years, 1 month ago (2016-11-15 20:34:16 UTC) #37
commit-bot: I haz the power
Try jobs failed on following builders: cast_shell_linux on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/cast_shell_linux/builds/260973)
4 years, 1 month ago (2016-11-15 20:47:48 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/2498743002/120001
4 years, 1 month ago (2016-11-15 20:50:34 UTC) #41
commit-bot: I haz the power
Try jobs failed on following builders: cast_shell_linux on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/cast_shell_linux/builds/261002)
4 years, 1 month ago (2016-11-15 21:08:18 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/2498743002/120001
4 years, 1 month ago (2016-11-15 23:56:24 UTC) #45
commit-bot: I haz the power
Committed patchset #7 (id:120001)
4 years, 1 month ago (2016-11-16 06:24:00 UTC) #47
commit-bot: I haz the power
4 years, 1 month ago (2016-11-16 06:29:46 UTC) #49
Message was sent while issue was closed.
Patchset 7 (id:??) landed as
https://crrev.com/64c7ea9ccda1354968015f4979135760627435e1
Cr-Commit-Position: refs/heads/master@{#432387}

Powered by Google App Engine
This is Rietveld 408576698