class ChannelArguments

Defined at line 39 of file ../../third_party/grpc-migrating/src/include/grpcpp/support/channel_arguments.h

Options for channel creation. The user can use generic setters to pass

key value pairs down to C channel creation code. For gRPC related options,

concrete setters are provided.

Public Methods

void ChannelArguments ()
void ~ChannelArguments ()
void ChannelArguments (const ChannelArguments & other)
void Swap (ChannelArguments & other)
void SetChannelArgs (grpc_channel_args * channel_args)

Dump arguments in this instance to

Does not take

ownership of

Note that the underlying arguments are shared. Changes made to either

or this instance would be reflected on both.

void SetSslTargetNameOverride (const std::string & name)

gRPC specific channel argument setters

Set target name override for SSL host name checking. This option should

be used with caution in production.

void SetCompressionAlgorithm (grpc_compression_algorithm algorithm)

TODO(yangg) add flow control options

Set the compression algorithm for the channel.

void SetGrpclbFallbackTimeout (int fallback_timeout)

Set the grpclb fallback timeout (in ms) for the channel. If this amount

of time has passed but we have not gotten any non-empty

from

the balancer, we will fall back to use the backend address(es) returned by

the resolver.

void SetSocketMutator (grpc_socket_mutator * mutator)

Set a mutator for the underlying socket.

void SetUserAgentPrefix (const std::string & user_agent_prefix)

Set the string to prepend to the user agent.

void SetResourceQuota (const grpc::ResourceQuota & resource_quota)

Set the buffer pool to be attached to the constructed channel.

void SetMaxReceiveMessageSize (int size)

Set the max receive and send message sizes.

void SetMaxSendMessageSize (int size)
void SetLoadBalancingPolicyName (const std::string & lb_policy_name)

Set LB policy name.

Note that if the name resolver returns only balancer addresses, the

grpclb LB policy will be used, regardless of what is specified here.

void SetServiceConfigJSON (const std::string & service_config_json)

Set service config in JSON form.

Primarily meant for use in unit tests.

void SetInt (const std::string & key, int value)

Generic channel argument setter. Only for advanced use cases.

Set an integer argument

under

void SetPointer (const std::string & key, void * value)

Generic channel argument setter. Only for advanced use cases.

Set a pointer argument

under

Ownership is not

transferred.

void SetPointerWithVtable (const std::string & key, void * value, const grpc_arg_pointer_vtable * vtable)

Set a pointer argument

under

transferring ownership of

to the

object. The

function

is responsible for

cleanup/destruction when called.

void SetString (const std::string & key, const std::string & value)

Set a textual argument

under

ChannelArguments & operator= (ChannelArguments other)

Defined at line 45 of file ../../third_party/grpc-migrating/src/include/grpcpp/support/channel_arguments.h

grpc_channel_args c_channel_args ()

Return (by value) a C

structure which points to

arguments owned by this

instance

Defined at line 115 of file ../../third_party/grpc-migrating/src/include/grpcpp/support/channel_arguments.h

Friends

class ChannelArgumentsTest
class ChannelCredentials