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

Issue 664763002: Mojo: Change the way message pipes are passed over channels. (Closed)

Created:
6 years, 2 months ago by viettrungluu
Modified:
6 years, 2 months ago
Reviewers:
brettw
CC:
chromium-reviews, qsr+mojo_chromium.org, viettrungluu+watch_chromium.org, yzshen+watch_chromium.org, abarth-chromium, Aaron Boodman, darin (slow to review), ben+mojo_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git/+/master
Project:
chromium
Visibility:
Public.

Description

Mojo: Change the way message pipes are passed over channels. Before: * We'd send the message "containing" the message pipe (handle) first. * Upon receiving it, the other side would create an endpoint (and dispatcher, etc.) * The other side then sent a message back indicating the new ID (and telling the first side to run the message pipe. * Upon receiving that "run" message, the first side would start sending messages for that message pipe. This makes for rather complicated handshaking, which would only get more complicated if, e.g., the second side wanted to forward the message pipe handle that it received to someone else (e.g., over another channel). Now: * We "remotely allocate" an ID for the other side and send a message telling it to create an endpoint with that ID. * We forward all the messages queued to that message pipe endpoint immediately (since we already know the destination ID). * We send the message "containing" the message pipe (handle). * The other side then creates a dispatcher and associates it with the (already-existing) endpoint. Still to do: * We need to track IDs that we've allocated for the remote side more carefully (in case of wrap-around, to avoid collisions). * Convert everything over to the "attach and run" mode of operation (and possibly rename "attach and run" to something shorter), and delete the various separate "attach" and "run" methods. R=brettw@chromium.org Committed: https://crrev.com/df8e15ae21198cb6ac1587a07a179fa26655048c Cr-Commit-Position: refs/heads/master@{#300157}

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+135 lines, -100 lines) Patch
M mojo/edk/system/channel.h View 4 chunks +27 lines, -19 lines 0 comments Download
M mojo/edk/system/channel.cc View 7 chunks +81 lines, -40 lines 0 comments Download
M mojo/edk/system/message_in_transit.h View 1 chunk +2 lines, -1 line 0 comments Download
M mojo/edk/system/message_in_transit.cc View 1 chunk +1 line, -1 line 0 comments Download
M mojo/edk/system/message_pipe_dispatcher.cc View 3 chunks +24 lines, -39 lines 0 comments Download

Messages

Total messages: 7 (1 generated)
viettrungluu
6 years, 2 months ago (2014-10-17 17:49:14 UTC) #1
brettw
LGTM. How does the forwarding case work in the new design? It seems like the ...
6 years, 2 months ago (2014-10-17 20:11:13 UTC) #2
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/664763002/1
6 years, 2 months ago (2014-10-17 20:27:34 UTC) #4
viettrungluu
On 2014/10/17 20:11:13, brettw wrote: > LGTM. How does the forwarding case work in the ...
6 years, 2 months ago (2014-10-17 20:30:50 UTC) #5
commit-bot: I haz the power
Committed patchset #1 (id:1)
6 years, 2 months ago (2014-10-17 20:41:08 UTC) #6
commit-bot: I haz the power
6 years, 2 months ago (2014-10-17 20:43:26 UTC) #7
Message was sent while issue was closed.
Patchset 1 (id:??) landed as
https://crrev.com/df8e15ae21198cb6ac1587a07a179fa26655048c
Cr-Commit-Position: refs/heads/master@{#300157}

Powered by Google App Engine
This is Rietveld 408576698