Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
G
Grpc
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
tci-gateway-module
Grpc
Commits
15eba139
Commit
15eba139
authored
8 years ago
by
David Garcia Quintas
Browse files
Options
Downloads
Patches
Plain Diff
Improved some docstrings for grpc_call creation
parent
328f7bfe
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
include/grpc/grpc.h
+5
-3
5 additions, 3 deletions
include/grpc/grpc.h
src/core/ext/lb_policy/grpclb/grpclb.c
+3
-0
3 additions, 0 deletions
src/core/ext/lb_policy/grpclb/grpclb.c
src/core/lib/surface/channel.h
+8
-0
8 additions, 0 deletions
src/core/lib/surface/channel.h
with
16 additions
and
3 deletions
include/grpc/grpc.h
+
5
−
3
View file @
15eba139
...
@@ -170,8 +170,9 @@ GRPCAPI void grpc_channel_watch_connectivity_state(
...
@@ -170,8 +170,9 @@ GRPCAPI void grpc_channel_watch_connectivity_state(
completions are sent to 'completion_queue'. 'method' and 'host' need only
completions are sent to 'completion_queue'. 'method' and 'host' need only
live through the invocation of this function.
live through the invocation of this function.
If parent_call is non-NULL, it must be a server-side call. It will be used
If parent_call is non-NULL, it must be a server-side call. It will be used
to propagate properties from the server call to this new client call.
to propagate properties from the server call to this new client call,
*/
depending on the value of \a propagation_mask (see propagation_bits.h for
possible values). */
GRPCAPI
grpc_call
*
grpc_channel_create_call
(
GRPCAPI
grpc_call
*
grpc_channel_create_call
(
grpc_channel
*
channel
,
grpc_call
*
parent_call
,
uint32_t
propagation_mask
,
grpc_channel
*
channel
,
grpc_call
*
parent_call
,
uint32_t
propagation_mask
,
grpc_completion_queue
*
completion_queue
,
const
char
*
method
,
grpc_completion_queue
*
completion_queue
,
const
char
*
method
,
...
@@ -187,7 +188,8 @@ GRPCAPI void *grpc_channel_register_call(grpc_channel *channel,
...
@@ -187,7 +188,8 @@ GRPCAPI void *grpc_channel_register_call(grpc_channel *channel,
const
char
*
method
,
const
char
*
host
,
const
char
*
method
,
const
char
*
host
,
void
*
reserved
);
void
*
reserved
);
/** Create a call given a handle returned from grpc_channel_register_call */
/** Create a call given a handle returned from grpc_channel_register_call.
\sa grpc_channel_create_call. */
GRPCAPI
grpc_call
*
grpc_channel_create_registered_call
(
GRPCAPI
grpc_call
*
grpc_channel_create_registered_call
(
grpc_channel
*
channel
,
grpc_call
*
parent_call
,
uint32_t
propagation_mask
,
grpc_channel
*
channel
,
grpc_call
*
parent_call
,
uint32_t
propagation_mask
,
grpc_completion_queue
*
completion_queue
,
void
*
registered_call_handle
,
grpc_completion_queue
*
completion_queue
,
void
*
registered_call_handle
,
...
...
This diff is collapsed.
Click to expand it.
src/core/ext/lb_policy/grpclb/grpclb.c
+
3
−
0
View file @
15eba139
...
@@ -767,6 +767,9 @@ static lb_client_data *lb_client_data_create(glb_lb_policy *glb_policy) {
...
@@ -767,6 +767,9 @@ static lb_client_data *lb_client_data_create(glb_lb_policy *glb_policy) {
lb_client
->
deadline
=
gpr_time_add
(
gpr_now
(
GPR_CLOCK_MONOTONIC
),
lb_client
->
deadline
=
gpr_time_add
(
gpr_now
(
GPR_CLOCK_MONOTONIC
),
gpr_time_from_seconds
(
3
,
GPR_TIMESPAN
));
gpr_time_from_seconds
(
3
,
GPR_TIMESPAN
));
/* Note the following LB call progresses every time there's activity in \a
* glb_policy->base.interested_parties, which is comprised of the polling
* entities passed to glb_pick(). */
lb_client
->
lb_call
=
grpc_channel_create_pollset_set_call
(
lb_client
->
lb_call
=
grpc_channel_create_pollset_set_call
(
glb_policy
->
lb_channel
,
NULL
,
GRPC_PROPAGATE_DEFAULTS
,
glb_policy
->
lb_channel
,
NULL
,
GRPC_PROPAGATE_DEFAULTS
,
glb_policy
->
base
.
interested_parties
,
"/BalanceLoad"
,
glb_policy
->
base
.
interested_parties
,
"/BalanceLoad"
,
...
...
This diff is collapsed.
Click to expand it.
src/core/lib/surface/channel.h
+
8
−
0
View file @
15eba139
...
@@ -42,6 +42,14 @@ grpc_channel *grpc_channel_create(grpc_exec_ctx *exec_ctx, const char *target,
...
@@ -42,6 +42,14 @@ grpc_channel *grpc_channel_create(grpc_exec_ctx *exec_ctx, const char *target,
grpc_channel_stack_type
channel_stack_type
,
grpc_channel_stack_type
channel_stack_type
,
grpc_transport
*
optional_transport
);
grpc_transport
*
optional_transport
);
/** Create a call given a grpc_channel, in order to call \a method.
Progress is tied to activity on \a pollset_set. The returned call object is
meant to be used with \a grpc_call_start_batch_and_execute, which relies on
callbacks to signal completions. \a method and \a host need
only live through the invocation of this function. If \a parent_call is
non-NULL, it must be a server-side call. It will be used to propagate
properties from the server call to this new client call, depending on the
value of \a propagation_mask (see propagation_bits.h for possible values) */
grpc_call
*
grpc_channel_create_pollset_set_call
(
grpc_call
*
grpc_channel_create_pollset_set_call
(
grpc_channel
*
channel
,
grpc_call
*
parent_call
,
uint32_t
propagation_mask
,
grpc_channel
*
channel
,
grpc_call
*
parent_call
,
uint32_t
propagation_mask
,
grpc_pollset_set
*
pollset_set
,
const
char
*
method
,
const
char
*
host
,
grpc_pollset_set
*
pollset_set
,
const
char
*
method
,
const
char
*
host
,
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment