diff options
author | 2014-12-17 16:36:59 -0800 | |
---|---|---|
committer | 2014-12-19 13:04:38 -0800 | |
commit | d79b4865ce124d12b2394c2755df8f6539418e93 (patch) | |
tree | c3fc33e4cf7d043e7cb61fe4a526e491554aaed1 /src/core/channel/client_channel.c | |
parent | a4b6f5df94d6293455f2fed86b56491b7f6dd39e (diff) |
Introduce the (outside-of-iomgr) pollset API.
This CL introduces the public side of this interface. There will need to be an
iomgr-private API also, but this will be a per-implementation API and so is not
covered here.
I've taken care of wiring the interface through the codebase in the manner that
I expect it will be used.
Change on 2014/12/17 by ctiller <ctiller@google.com>
-------------
Created by MOE: http://code.google.com/p/moe-java
MOE_MIGRATED_REVID=82376987
Diffstat (limited to 'src/core/channel/client_channel.c')
-rw-r--r-- | src/core/channel/client_channel.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/core/channel/client_channel.c b/src/core/channel/client_channel.c index a146a7b6a0..6329932330 100644 --- a/src/core/channel/client_channel.c +++ b/src/core/channel/client_channel.c @@ -98,6 +98,7 @@ struct call_data { void (*on_complete)(void *user_data, grpc_op_error error); void *on_complete_user_data; gpr_uint32 start_flags; + grpc_pollset *pollset; } waiting; } s; }; @@ -186,6 +187,7 @@ static void start_rpc(grpc_call_element *elem, grpc_call_op *op) { calld->s.waiting.on_complete = op->done_cb; calld->s.waiting.on_complete_user_data = op->user_data; calld->s.waiting.start_flags = op->flags; + calld->s.waiting.pollset = op->data.start.pollset; chand->waiting_children[chand->waiting_child_count++] = calld; gpr_mu_unlock(&chand->mu); @@ -523,6 +525,7 @@ grpc_transport_setup_result grpc_client_channel_transport_setup_complete( call_ops[i].done_cb = waiting_children[i]->s.waiting.on_complete; call_ops[i].user_data = waiting_children[i]->s.waiting.on_complete_user_data; + call_ops[i].data.start.pollset = waiting_children[i]->s.waiting.pollset; if (!prepare_activate(waiting_children[i]->elem, chand->active_child)) { waiting_children[i] = NULL; call_ops[i].done_cb(call_ops[i].user_data, GRPC_OP_ERROR); |