Classes | Macros | Typedefs | Enumerations
grpc_types.h File Reference
#include <grpc/impl/codegen/port_platform.h>
#include <stddef.h>
#include <grpc/impl/codegen/compression_types.h>
#include <grpc/impl/codegen/gpr_types.h>
#include <grpc/impl/codegen/slice.h>
#include <grpc/impl/codegen/status.h>
Include dependency graph for grpc_types.h:

Go to the source code of this file.

Classes

struct  grpc_arg
 
struct  grpc_arg::grpc_arg_value::grpc_arg_pointer
 
struct  grpc_arg_pointer_vtable
 
union  grpc_arg::grpc_arg_value
 
struct  grpc_byte_buffer
 
union  grpc_byte_buffer::grpc_byte_buffer_data
 
struct  grpc_call_details
 
struct  grpc_channel_args
 
struct  grpc_channel_info
 
struct  grpc_completion_queue_attributes
 
struct  grpc_completion_queue_functor
 
struct  grpc_byte_buffer::grpc_byte_buffer_data::grpc_compressed_buffer
 
struct  grpc_event
 
struct  grpc_metadata
 
struct  grpc_metadata_array
 
struct  grpc_op
 
union  grpc_op::grpc_op_data
 
struct  grpc_op::grpc_op_data::grpc_op_recv_close_on_server
 
struct  grpc_op::grpc_op_data::grpc_op_recv_initial_metadata
 
struct  grpc_op::grpc_op_data::grpc_op_recv_message
 
struct  grpc_op::grpc_op_data::grpc_op_recv_status_on_client
 
struct  grpc_op::grpc_op_data::grpc_op_send_initial_metadata
 
struct  grpc_op::grpc_op_data::grpc_op_send_initial_metadata::grpc_op_send_initial_metadata_maybe_compression_level
 
struct  grpc_op::grpc_op_data::grpc_op_send_message
 
struct  grpc_op::grpc_op_data::grpc_op_send_status_from_server
 

Macros

#define GRPC_ARG_ALLOW_REUSEPORT   "grpc.so_reuseport"
 
#define GRPC_ARG_AUTHORIZATION_POLICY_PROVIDER   "grpc.authorization_policy_provider"
 
#define GRPC_ARG_CHANNEL_ID   "grpc.channel_id"
 
#define GRPC_ARG_CHANNEL_POOL_DOMAIN   "grpc.channel_pooling_domain"
 
#define GRPC_ARG_CLIENT_IDLE_TIMEOUT_MS   "grpc.client_idle_timeout_ms"
 
#define GRPC_ARG_DEFAULT_AUTHORITY   "grpc.default_authority"
 
#define GRPC_ARG_DISABLE_CLIENT_AUTHORITY_FILTER   "grpc.disable_client_authority_filter"
 
#define GRPC_ARG_DNS_ARES_QUERY_TIMEOUT_MS   "grpc.dns_ares_query_timeout"
 
#define GRPC_ARG_DNS_ENABLE_SRV_QUERIES   "grpc.dns_enable_srv_queries"
 
#define GRPC_ARG_DNS_MIN_TIME_BETWEEN_RESOLUTIONS_MS   "grpc.dns_min_time_between_resolutions_ms"
 
#define GRPC_ARG_ENABLE_CENSUS   "grpc.census"
 
#define GRPC_ARG_ENABLE_CHANNELZ   "grpc.enable_channelz"
 
#define GRPC_ARG_ENABLE_DEADLINE_CHECKS   "grpc.enable_deadline_checking"
 
#define GRPC_ARG_ENABLE_HTTP_PROXY   "grpc.enable_http_proxy"
 
#define GRPC_ARG_ENABLE_LOAD_REPORTING   "grpc.loadreporting"
 
#define GRPC_ARG_ENABLE_PER_MESSAGE_COMPRESSION   "grpc.per_message_compression"
 
#define GRPC_ARG_ENABLE_PER_MESSAGE_DECOMPRESSION   "grpc.per_message_decompression"
 
#define GRPC_ARG_ENABLE_RETRIES   "grpc.enable_retries"
 
#define GRPC_ARG_EXPAND_WILDCARD_ADDRS   "grpc.expand_wildcard_addrs"
 
#define GRPC_ARG_EXPERIMENTAL_ENABLE_HEDGING   "grpc.experimental.enable_hedging"
 
#define GRPC_ARG_GRPCLB_CALL_TIMEOUT_MS   "grpc.grpclb_call_timeout_ms"
 
#define GRPC_ARG_GRPCLB_FALLBACK_TIMEOUT_MS   "grpc.grpclb_fallback_timeout_ms"
 
#define GRPC_ARG_HTTP2_BDP_PROBE   "grpc.http2.bdp_probe"
 
#define GRPC_ARG_HTTP2_ENABLE_TRUE_BINARY   "grpc.http2.true_binary"
 
#define GRPC_ARG_HTTP2_HPACK_TABLE_SIZE_DECODER   "grpc.http2.hpack_table_size.decoder"
 
#define GRPC_ARG_HTTP2_HPACK_TABLE_SIZE_ENCODER   "grpc.http2.hpack_table_size.encoder"
 
#define GRPC_ARG_HTTP2_INITIAL_SEQUENCE_NUMBER   "grpc.http2.initial_sequence_number"
 
#define GRPC_ARG_HTTP2_MAX_FRAME_SIZE   "grpc.http2.max_frame_size"
 
#define GRPC_ARG_HTTP2_MAX_PING_STRIKES   "grpc.http2.max_ping_strikes"
 
#define GRPC_ARG_HTTP2_MAX_PINGS_WITHOUT_DATA   "grpc.http2.max_pings_without_data"
 
#define GRPC_ARG_HTTP2_MIN_RECV_PING_INTERVAL_WITHOUT_DATA_MS   "grpc.http2.min_ping_interval_without_data_ms"
 
#define GRPC_ARG_HTTP2_MIN_SENT_PING_INTERVAL_WITHOUT_DATA_MS   "grpc.http2.min_time_between_pings_ms"
 
#define GRPC_ARG_HTTP2_SCHEME   "grpc.http2_scheme"
 
#define GRPC_ARG_HTTP2_STREAM_LOOKAHEAD_BYTES   "grpc.http2.lookahead_bytes"
 
#define GRPC_ARG_HTTP2_WRITE_BUFFER_SIZE   "grpc.http2.write_buffer_size"
 
#define GRPC_ARG_HTTP_PROXY   "grpc.http_proxy"
 
#define GRPC_ARG_INHIBIT_HEALTH_CHECKING   "grpc.inhibit_health_checking"
 
#define GRPC_ARG_INITIAL_RECONNECT_BACKOFF_MS   "grpc.initial_reconnect_backoff_ms"
 
#define GRPC_ARG_KEEPALIVE_PERMIT_WITHOUT_CALLS   "grpc.keepalive_permit_without_calls"
 
#define GRPC_ARG_KEEPALIVE_TIME_MS   "grpc.keepalive_time_ms"
 
#define GRPC_ARG_KEEPALIVE_TIMEOUT_MS   "grpc.keepalive_timeout_ms"
 
#define GRPC_ARG_LB_POLICY_NAME   "grpc.lb_policy_name"
 
#define GRPC_ARG_MAX_CHANNEL_TRACE_EVENT_MEMORY_PER_NODE   "grpc.max_channel_trace_event_memory_per_node"
 
#define GRPC_ARG_MAX_CONCURRENT_STREAMS   "grpc.max_concurrent_streams"
 
#define GRPC_ARG_MAX_CONNECTION_AGE_GRACE_MS   "grpc.max_connection_age_grace_ms"
 
#define GRPC_ARG_MAX_CONNECTION_AGE_MS   "grpc.max_connection_age_ms"
 
#define GRPC_ARG_MAX_CONNECTION_IDLE_MS   "grpc.max_connection_idle_ms"
 
#define GRPC_ARG_MAX_MESSAGE_LENGTH   GRPC_ARG_MAX_RECEIVE_MESSAGE_LENGTH
 
#define GRPC_ARG_MAX_METADATA_SIZE   "grpc.max_metadata_size"
 
#define GRPC_ARG_MAX_RECEIVE_MESSAGE_LENGTH   "grpc.max_receive_message_length"
 
#define GRPC_ARG_MAX_RECONNECT_BACKOFF_MS   "grpc.max_reconnect_backoff_ms"
 
#define GRPC_ARG_MAX_SEND_MESSAGE_LENGTH   "grpc.max_send_message_length"
 
#define GRPC_ARG_MIN_RECONNECT_BACKOFF_MS   "grpc.min_reconnect_backoff_ms"
 
#define GRPC_ARG_MINIMAL_STACK   "grpc.minimal_stack"
 
#define GRPC_ARG_MOBILE_LOG_CONTEXT   "grpc.mobile_log_context"
 
#define GRPC_ARG_OPTIMIZATION_TARGET   "grpc.optimization_target"
 
#define GRPC_ARG_PER_RPC_RETRY_BUFFER_SIZE   "grpc.per_rpc_retry_buffer_size"
 
#define GRPC_ARG_PRIMARY_USER_AGENT_STRING   "grpc.primary_user_agent"
 
#define GRPC_ARG_PRIORITY_FAILOVER_TIMEOUT_MS   "grpc.priority_failover_timeout_ms"
 
#define GRPC_ARG_RESOURCE_QUOTA   "grpc.resource_quota"
 
#define GRPC_ARG_SECONDARY_USER_AGENT_STRING   "grpc.secondary_user_agent"
 
#define GRPC_ARG_SERVER_CONFIG_CHANGE_DRAIN_GRACE_TIME_MS   "grpc.experimental.server_config_change_drain_grace_time_ms"
 
#define GRPC_ARG_SERVER_HANDSHAKE_TIMEOUT_MS   "grpc.server_handshake_timeout_ms"
 
#define GRPC_ARG_SERVICE_CONFIG   "grpc.service_config"
 
#define GRPC_ARG_SERVICE_CONFIG_DISABLE_RESOLUTION   "grpc.service_config_disable_resolution"
 
#define GRPC_ARG_SOCKET_FACTORY   "grpc.socket_factory"
 
#define GRPC_ARG_SOCKET_MUTATOR   "grpc.socket_mutator"
 
#define GRPC_ARG_SURFACE_USER_AGENT   "grpc.surface_user_agent"
 
#define GRPC_ARG_TCP_MAX_READ_CHUNK_SIZE   "grpc.experimental.tcp_max_read_chunk_size"
 
#define GRPC_ARG_TCP_MIN_READ_CHUNK_SIZE   "grpc.experimental.tcp_min_read_chunk_size"
 
#define GRPC_ARG_TCP_READ_CHUNK_SIZE   "grpc.experimental.tcp_read_chunk_size"
 
#define GRPC_ARG_TCP_TX_ZEROCOPY_ENABLED   "grpc.experimental.tcp_tx_zerocopy_enabled"
 
#define GRPC_ARG_TCP_TX_ZEROCOPY_MAX_SIMULT_SENDS   "grpc.experimental.tcp_tx_zerocopy_max_simultaneous_sends"
 
#define GRPC_ARG_TCP_TX_ZEROCOPY_SEND_BYTES_THRESHOLD   "grpc.experimental.tcp_tx_zerocopy_send_bytes_threshold"
 
#define GRPC_ARG_TEST_ONLY_DO_NOT_USE_IN_PROD_XDS_BOOTSTRAP_CONFIG   "grpc.TEST_ONLY_DO_NOT_USE_IN_PROD.xds_bootstrap_config"
 
#define GRPC_ARG_TSI_MAX_FRAME_SIZE   "grpc.tsi.max_frame_size"
 
#define GRPC_ARG_USE_CRONET_PACKET_COALESCING   "grpc.use_cronet_packet_coalescing"
 
#define GRPC_ARG_USE_LOCAL_SUBCHANNEL_POOL   "grpc.use_local_subchannel_pool"
 
#define GRPC_ARG_WORKAROUND_CRONET_COMPRESSION   "grpc.workaround.cronet_compression"
 
#define GRPC_CQ_CURRENT_VERSION   2
 
#define GRPC_CQ_VERSION_MINIMUM_FOR_CALLBACKABLE   2
 
#define GRPC_DEFAULT_MAX_RECV_MESSAGE_LENGTH   (4 * 1024 * 1024)
 
#define GRPC_DEFAULT_MAX_SEND_MESSAGE_LENGTH   (-1)
 
#define GRPC_INITIAL_METADATA_CORKED   (0x00000100u)
 
#define GRPC_INITIAL_METADATA_USED_MASK
 
#define GRPC_INITIAL_METADATA_WAIT_FOR_READY   (0x00000020u)
 
#define GRPC_INITIAL_METADATA_WAIT_FOR_READY_EXPLICITLY_SET   (0x00000080u)
 
#define GRPC_SSL_SESSION_CACHE_ARG   "grpc.ssl_session_cache"
 
#define GRPC_SSL_TARGET_NAME_OVERRIDE_ARG   "grpc.ssl_target_name_override"
 
#define GRPC_TCP_DEFAULT_READ_SLICE_SIZE   8192
 
#define GRPC_WRITE_BUFFER_HINT   (0x00000001u)
 
#define GRPC_WRITE_NO_COMPRESS   (0x00000002u)
 
#define GRPC_WRITE_THROUGH   (0x00000004u)
 
#define GRPC_WRITE_USED_MASK   (GRPC_WRITE_BUFFER_HINT | GRPC_WRITE_NO_COMPRESS | GRPC_WRITE_THROUGH)
 

Typedefs

typedef struct grpc_arg_pointer_vtable grpc_arg_pointer_vtable
 
typedef struct grpc_byte_buffer grpc_byte_buffer
 
typedef struct grpc_call grpc_call
 
typedef enum grpc_call_error grpc_call_error
 
typedef struct grpc_channel grpc_channel
 
typedef struct grpc_completion_queue grpc_completion_queue
 
typedef struct grpc_completion_queue_attributes grpc_completion_queue_attributes
 
typedef struct grpc_completion_queue_factory grpc_completion_queue_factory
 
typedef struct grpc_completion_queue_functor grpc_completion_queue_functor
 
typedef enum grpc_completion_type grpc_completion_type
 
typedef struct grpc_event grpc_event
 
typedef struct grpc_metadata grpc_metadata
 
typedef struct grpc_op grpc_op
 
typedef struct grpc_resource_quota grpc_resource_quota
 
typedef struct grpc_server grpc_server
 
typedef struct grpc_socket_factory grpc_socket_factory
 
typedef struct grpc_socket_mutator grpc_socket_mutator
 

Enumerations

enum  grpc_arg_type { GRPC_ARG_STRING, GRPC_ARG_INTEGER, GRPC_ARG_POINTER }
 
enum  grpc_byte_buffer_type { GRPC_BB_RAW }
 
enum  grpc_call_error {
  GRPC_CALL_OK = 0, GRPC_CALL_ERROR, GRPC_CALL_ERROR_NOT_ON_SERVER, GRPC_CALL_ERROR_NOT_ON_CLIENT,
  GRPC_CALL_ERROR_ALREADY_ACCEPTED, GRPC_CALL_ERROR_ALREADY_INVOKED, GRPC_CALL_ERROR_NOT_INVOKED, GRPC_CALL_ERROR_ALREADY_FINISHED,
  GRPC_CALL_ERROR_TOO_MANY_OPERATIONS, GRPC_CALL_ERROR_INVALID_FLAGS, GRPC_CALL_ERROR_INVALID_METADATA, GRPC_CALL_ERROR_INVALID_MESSAGE,
  GRPC_CALL_ERROR_NOT_SERVER_COMPLETION_QUEUE, GRPC_CALL_ERROR_BATCH_TOO_BIG, GRPC_CALL_ERROR_PAYLOAD_TYPE_MISMATCH, GRPC_CALL_ERROR_COMPLETION_QUEUE_SHUTDOWN
}
 
enum  grpc_completion_type { GRPC_QUEUE_SHUTDOWN, GRPC_QUEUE_TIMEOUT, GRPC_OP_COMPLETE }
 
enum  grpc_cq_completion_type { GRPC_CQ_NEXT, GRPC_CQ_PLUCK, GRPC_CQ_CALLBACK }
 
enum  grpc_cq_polling_type { GRPC_CQ_DEFAULT_POLLING, GRPC_CQ_NON_LISTENING, GRPC_CQ_NON_POLLING }
 
enum  grpc_op_type {
  GRPC_OP_SEND_INITIAL_METADATA = 0, GRPC_OP_SEND_MESSAGE, GRPC_OP_SEND_CLOSE_FROM_CLIENT, GRPC_OP_SEND_STATUS_FROM_SERVER,
  GRPC_OP_RECV_INITIAL_METADATA, GRPC_OP_RECV_MESSAGE, GRPC_OP_RECV_STATUS_ON_CLIENT, GRPC_OP_RECV_CLOSE_ON_SERVER
}
 

Macro Definition Documentation

◆ GRPC_CQ_CURRENT_VERSION

#define GRPC_CQ_CURRENT_VERSION   2

Definition at line 789 of file grpc_types.h.

◆ GRPC_CQ_VERSION_MINIMUM_FOR_CALLBACKABLE

#define GRPC_CQ_VERSION_MINIMUM_FOR_CALLBACKABLE   2

Definition at line 790 of file grpc_types.h.

◆ GRPC_DEFAULT_MAX_RECV_MESSAGE_LENGTH

#define GRPC_DEFAULT_MAX_RECV_MESSAGE_LENGTH   (4 * 1024 * 1024)

Definition at line 504 of file grpc_types.h.

◆ GRPC_DEFAULT_MAX_SEND_MESSAGE_LENGTH

#define GRPC_DEFAULT_MAX_SEND_MESSAGE_LENGTH   (-1)

Default send/receive message size limits in bytes. -1 for unlimited. TODO(roth) Make this match the default receive limit after next release

Definition at line 503 of file grpc_types.h.

◆ GRPC_INITIAL_METADATA_CORKED

#define GRPC_INITIAL_METADATA_CORKED   (0x00000100u)

Signal that the initial metadata should be corked

Definition at line 528 of file grpc_types.h.

◆ GRPC_INITIAL_METADATA_USED_MASK

#define GRPC_INITIAL_METADATA_USED_MASK
Value:
GRPC_INITIAL_METADATA_WAIT_FOR_READY | GRPC_INITIAL_METADATA_CORKED | \
GRPC_WRITE_THROUGH)

Mask of all valid flags

Definition at line 531 of file grpc_types.h.

◆ GRPC_INITIAL_METADATA_WAIT_FOR_READY

#define GRPC_INITIAL_METADATA_WAIT_FOR_READY   (0x00000020u)

Initial metadata flags These flags are to be passed to the grpc_op::flags field Signal that the call should not return UNAVAILABLE before it has started

Definition at line 523 of file grpc_types.h.

◆ GRPC_INITIAL_METADATA_WAIT_FOR_READY_EXPLICITLY_SET

#define GRPC_INITIAL_METADATA_WAIT_FOR_READY_EXPLICITLY_SET   (0x00000080u)

Signal that GRPC_INITIAL_METADATA_WAIT_FOR_READY was explicitly set by the calling application.

Definition at line 526 of file grpc_types.h.

◆ GRPC_WRITE_BUFFER_HINT

#define GRPC_WRITE_BUFFER_HINT   (0x00000001u)

Write Flags: Hint that the write may be buffered and need not go out on the wire immediately. GRPC is free to buffer the message until the next non-buffered write, or until writes_done, but it need not buffer completely or at all.

Definition at line 510 of file grpc_types.h.

◆ GRPC_WRITE_NO_COMPRESS

#define GRPC_WRITE_NO_COMPRESS   (0x00000002u)

Force compression to be disabled for a particular write (start_write/add_metadata). Illegal on invoke/accept.

Definition at line 513 of file grpc_types.h.

◆ GRPC_WRITE_THROUGH

#define GRPC_WRITE_THROUGH   (0x00000004u)

Force this message to be written to the socket before completing it

Definition at line 515 of file grpc_types.h.

◆ GRPC_WRITE_USED_MASK

#define GRPC_WRITE_USED_MASK   (GRPC_WRITE_BUFFER_HINT | GRPC_WRITE_NO_COMPRESS | GRPC_WRITE_THROUGH)

Mask of all valid flags.

Definition at line 517 of file grpc_types.h.

Typedef Documentation

◆ grpc_arg_pointer_vtable

◆ grpc_byte_buffer

◆ grpc_call

typedef struct grpc_call grpc_call

A Call represents an RPC. When created, it is in a configuration state allowing properties to be set until it is invoked. After invoke, the Call can have messages written to it and read from it.

Definition at line 70 of file grpc_types.h.

◆ grpc_call_error

Result of a grpc call. If the caller satisfies the prerequisites of a particular operation, the grpc_call_error returned will be GRPC_CALL_OK. Receiving any other value listed here is an indication of a bug in the caller.

◆ grpc_channel

typedef struct grpc_channel grpc_channel

The Channel interface allows creation of Call objects.

Definition at line 62 of file grpc_types.h.

◆ grpc_completion_queue

Completion Queues enable notification of the completion of asynchronous actions.

Definition at line 59 of file grpc_types.h.

◆ grpc_completion_queue_attributes

◆ grpc_completion_queue_factory

The completion queue factory structure is opaque to the callers of grpc

Definition at line 811 of file grpc_types.h.

◆ grpc_completion_queue_functor

Specifies an interface class to be used as a tag for callback-based completion queues. This can be used directly, as the first element of a struct in C, or as a base class in C++. Its "run" value should be assigned to some non-member function, such as a static method.

◆ grpc_completion_type

The type of completion (for grpc_event)

◆ grpc_event

typedef struct grpc_event grpc_event

The result of an operation.

Returned by a completion queue when the operation started with tag.

◆ grpc_metadata

typedef struct grpc_metadata grpc_metadata

A single metadata element

◆ grpc_op

typedef struct grpc_op grpc_op

Operation data: one field for each op type (except SEND_CLOSE_FROM_CLIENT which has no arguments)

◆ grpc_resource_quota

Definition at line 729 of file grpc_types.h.

◆ grpc_server

typedef struct grpc_server grpc_server

A server listens to some port and responds to request calls

Definition at line 65 of file grpc_types.h.

◆ grpc_socket_factory

The Socket Factory interface creates and binds sockets

Definition at line 76 of file grpc_types.h.

◆ grpc_socket_mutator

The Socket Mutator interface allows changes on socket options

Definition at line 73 of file grpc_types.h.

Enumeration Type Documentation

◆ grpc_arg_type

Type specifier for grpc_arg

Enumerator
GRPC_ARG_STRING 
GRPC_ARG_INTEGER 
GRPC_ARG_POINTER 

Definition at line 79 of file grpc_types.h.

◆ grpc_byte_buffer_type

Enumerator
GRPC_BB_RAW 

Future types may include GRPC_BB_PROTOBUF, etc.

Definition at line 38 of file grpc_types.h.

◆ grpc_call_error

Result of a grpc call. If the caller satisfies the prerequisites of a particular operation, the grpc_call_error returned will be GRPC_CALL_OK. Receiving any other value listed here is an indication of a bug in the caller.

Enumerator
GRPC_CALL_OK 

everything went ok

GRPC_CALL_ERROR 

something failed, we don't know what

GRPC_CALL_ERROR_NOT_ON_SERVER 

this method is not available on the server

GRPC_CALL_ERROR_NOT_ON_CLIENT 

this method is not available on the client

GRPC_CALL_ERROR_ALREADY_ACCEPTED 

this method must be called before server_accept

GRPC_CALL_ERROR_ALREADY_INVOKED 

this method must be called before invoke

GRPC_CALL_ERROR_NOT_INVOKED 

this method must be called after invoke

GRPC_CALL_ERROR_ALREADY_FINISHED 

this call is already finished (writes_done or write_status has already been called)

GRPC_CALL_ERROR_TOO_MANY_OPERATIONS 

there is already an outstanding read/write operation on the call

GRPC_CALL_ERROR_INVALID_FLAGS 

the flags value was illegal for this call

GRPC_CALL_ERROR_INVALID_METADATA 

invalid metadata was passed to this call

GRPC_CALL_ERROR_INVALID_MESSAGE 

invalid message was passed to this call

GRPC_CALL_ERROR_NOT_SERVER_COMPLETION_QUEUE 

completion queue for notification has not been registered with the server

GRPC_CALL_ERROR_BATCH_TOO_BIG 

this batch of operations leads to more operations than allowed

GRPC_CALL_ERROR_PAYLOAD_TYPE_MISMATCH 

payload type requested is not the type registered

GRPC_CALL_ERROR_COMPLETION_QUEUE_SHUTDOWN 

completion queue has been shutdown

Definition at line 464 of file grpc_types.h.

◆ grpc_completion_type

The type of completion (for grpc_event)

Enumerator
GRPC_QUEUE_SHUTDOWN 

Shutting down

GRPC_QUEUE_TIMEOUT 

No event before timeout

GRPC_OP_COMPLETE 

Operation completion

Definition at line 552 of file grpc_types.h.

◆ grpc_cq_completion_type

Specifies the type of APIs to use to pop events from the completion queue

Enumerator
GRPC_CQ_NEXT 

Events are popped out by calling grpc_completion_queue_next() API ONLY

GRPC_CQ_PLUCK 

Events are popped out by calling grpc_completion_queue_pluck() API ONLY

GRPC_CQ_CALLBACK 

Events trigger a callback specified as the tag

Definition at line 758 of file grpc_types.h.

◆ grpc_cq_polling_type

Completion queues internally MAY maintain a set of file descriptors in a structure called 'pollset'. This enum specifies if a completion queue has an associated pollset and any restrictions on the type of file descriptors that can be present in the pollset.

I/O progress can only be made when grpc_completion_queue_next() or grpc_completion_queue_pluck() are called on the completion queue (unless the grpc_cq_polling_type is GRPC_CQ_NON_POLLING) and hence it is very important to actively call these APIs

Enumerator
GRPC_CQ_DEFAULT_POLLING 

The completion queue will have an associated pollset and there is no restriction on the type of file descriptors the pollset may contain

GRPC_CQ_NON_LISTENING 

Similar to GRPC_CQ_DEFAULT_POLLING except that the completion queues will not contain any 'listening file descriptors' (i.e file descriptors used to listen to incoming channels)

GRPC_CQ_NON_POLLING 

The completion queue will not have an associated pollset. Note that grpc_completion_queue_next() or grpc_completion_queue_pluck() MUST still be called to pop events from the completion queue; it is not required to call them actively to make I/O progress

Definition at line 740 of file grpc_types.h.

◆ grpc_op_type

Enumerator
GRPC_OP_SEND_INITIAL_METADATA 

Send initial metadata: one and only one instance MUST be sent for each call, unless the call was cancelled - in which case this can be skipped. This op completes after all bytes of metadata have been accepted by outgoing flow control.

GRPC_OP_SEND_MESSAGE 

Send a message: 0 or more of these operations can occur for each call. This op completes after all bytes for the message have been accepted by outgoing flow control.

GRPC_OP_SEND_CLOSE_FROM_CLIENT 

Send a close from the client: one and only one instance MUST be sent from the client, unless the call was cancelled - in which case this can be skipped. This op completes after all bytes for the call (including the close) have passed outgoing flow control.

GRPC_OP_SEND_STATUS_FROM_SERVER 

Send status from the server: one and only one instance MUST be sent from the server unless the call was cancelled - in which case this can be skipped. This op completes after all bytes for the call (including the status) have passed outgoing flow control.

GRPC_OP_RECV_INITIAL_METADATA 

Receive initial metadata: one and only one MUST be made on the client, must not be made on the server. This op completes after all initial metadata has been read from the peer.

GRPC_OP_RECV_MESSAGE 

Receive a message: 0 or more of these operations can occur for each call. This op completes after all bytes of the received message have been read, or after a half-close has been received on this call.

GRPC_OP_RECV_STATUS_ON_CLIENT 

Receive status on the client: one and only one must be made on the client. This operation always succeeds, meaning ops paired with this operation will also appear to succeed, even though they may not have. In that case the status will indicate some failure. This op completes after all activity on the call has completed.

GRPC_OP_RECV_CLOSE_ON_SERVER 

Receive close on the server: one and only one must be made on the server. This op completes after the close has been received by the server. This operation always succeeds, meaning ops paired with this operation will also appear to succeed, even though they may not have.

Definition at line 593 of file grpc_types.h.

GRPC_INITIAL_METADATA_WAIT_FOR_READY_EXPLICITLY_SET
#define GRPC_INITIAL_METADATA_WAIT_FOR_READY_EXPLICITLY_SET
Definition: grpc_types.h:526
GRPC_INITIAL_METADATA_CORKED
#define GRPC_INITIAL_METADATA_CORKED
Definition: grpc_types.h:528


grpc
Author(s):
autogenerated on Fri May 16 2025 03:01:16