|
GRPC C++
1.0.0
|
Namespaces | |
| internal | |
| testing | |
Data Structures | |
| class | Alarm |
| A thin wrapper around grpc_alarm (see / / src/core/surface/alarm.h). More... | |
| class | AsyncGenericService |
| class | AsyncReaderInterface |
| An interface that yields a sequence of messages of type R. More... | |
| class | AsyncWriterInterface |
| An interface that can be fed a sequence of messages of type W. More... | |
| class | AuthContext |
| Class encapsulating the Authentication Information. More... | |
| class | AuthMetadataProcessor |
| class | AuthPropertyIterator |
| class | BidiStreamingHandler |
| class | ByteBuffer |
| A sequence of bytes. More... | |
| class | Call |
| class | CallCredentials |
| A call credentials object encapsulates the state needed by a client to authenticate with a server for a given call on a channel. More... | |
| class | CallHook |
| Channel and Server implement this to allow them to hook performing ops. More... | |
| class | CallNoOp |
| Default argument for CallOpSet. More... | |
| class | CallOpClientRecvStatus |
| class | CallOpClientSendClose |
| class | CallOpGenericRecvMessage |
| class | CallOpRecvInitialMetadata |
| class | CallOpRecvMessage |
| class | CallOpSendInitialMetadata |
| class | CallOpSendMessage |
| class | CallOpServerSendStatus |
| class | CallOpSet |
| Primary implementaiton of CallOpSetInterface. More... | |
| class | CallOpSetCollectionInterface |
| An abstract collection of CallOpSet's, to be used whenever CallOpSet objects must be thought of as a group. More... | |
| class | CallOpSetInterface |
| An abstract collection of call ops, used to generate the grpc_call_op structure to pass down to the lower layers, and as it is-a CompletionQueueTag, also massages the final completion into the correct form for consumption in the C++ API. More... | |
| class | Channel |
| Channels represent a connection to an endpoint. Created by CreateChannel. More... | |
| class | ChannelArguments |
| Options for channel creation. More... | |
| class | ChannelCredentials |
| A channel credentials object encapsulates all the state needed by a client to authenticate with a server for a given channel. More... | |
| class | ChannelInterface |
| Codegen interface for grpc::Channel. More... | |
| class | ClientAsyncReader |
| class | ClientAsyncReaderInterface |
| class | ClientAsyncReaderWriter |
| class | ClientAsyncReaderWriterInterface |
| Client-side interface for asynchronous bi-directional streaming. More... | |
| class | ClientAsyncResponseReader |
| class | ClientAsyncResponseReaderInterface |
| class | ClientAsyncStreamingInterface |
| Common interface for all client side asynchronous streaming. More... | |
| class | ClientAsyncWriter |
| class | ClientAsyncWriterInterface |
| Common interface for client side asynchronous writing. More... | |
| class | ClientContext |
| class | ClientReader |
| class | ClientReaderInterface |
| Client-side interface for streaming reads of message of type R. More... | |
| class | ClientReaderWriter |
| class | ClientReaderWriterInterface |
| Client-side interface for bi-directional streaming. More... | |
| class | ClientStreamingHandler |
| class | ClientStreamingInterface |
| Common interface for all synchronous client side streaming. More... | |
| class | ClientWriter |
| class | ClientWriterInterface |
| Client-side interface for streaming writes of message of type W. More... | |
| class | CompletionQueue |
| A thin wrapper around grpc_completion_queue (see / src/core/surface/completion_queue.h). More... | |
| class | CompletionQueueTag |
| An interface allowing implementors to process and filter event tags. More... | |
| class | condition_variable |
| class | CoreCodegen |
| Implementation of the core codegen interface. More... | |
| class | CoreCodegenInterface |
| Interface between the codegen library and the minimal subset of core features required by the generated code. More... | |
| class | GenericServerContext |
| class | GenericStub |
| class | GrpcLibraryCodegen |
| Classes that require gRPC to be initialized should inherit from this class. More... | |
| class | GrpcLibraryInterface |
| class | lock_guard |
| class | MetadataCredentialsPlugin |
| class | MethodHandler |
| class | mutex |
| class | PropagationOptions |
| Options for ClientContext::FromServerContext specifying which traits from the ServerContext to propagate (copy) from it into a new ClientContext. More... | |
| class | ReaderInterface |
| An interface that yields a sequence of messages of type R. More... | |
| class | RpcMethod |
| class | RpcMethodHandler |
| class | RpcServiceMethod |
| class | SerializationTraits |
| Defines how to serialize and deserialize some type. More... | |
| class | SerializationTraits< ByteBuffer, void > |
| class | Server |
| Models a gRPC server. More... | |
| class | ServerAsyncReader |
| class | ServerAsyncReaderInterface |
| class | ServerAsyncReaderWriter |
| class | ServerAsyncReaderWriterInterface |
| Server-side interface for asynchronous bi-directional streaming. More... | |
| class | ServerAsyncResponseWriter |
| class | ServerAsyncStreamingInterface |
| class | ServerAsyncWriter |
| class | ServerAsyncWriterInterface |
| class | ServerBuilder |
| A builder class for the creation and startup of grpc::Server instances. More... | |
| class | ServerBuilderOption |
| Interface to pass an option to a ServerBuilder. More... | |
| class | ServerBuilderPlugin |
| class | ServerCompletionQueue |
| A specific type of completion queue used by the processing of notifications by servers. More... | |
| class | ServerContext |
| class | ServerCredentials |
| class | ServerInitializer |
| class | ServerInterface |
| Models a gRPC server. More... | |
| class | ServerReader |
| class | ServerReaderWriter |
| Server-side interface for bi-directional streaming. More... | |
| class | ServerStreamingHandler |
| class | ServerWriter |
| class | Service |
| class | Slice |
| A wrapper around gpr_slice. More... | |
| class | SneakyCallOpSet |
| A CallOpSet that does not post completions to the completion queue. More... | |
| struct | SslCredentialsOptions |
| Options used to build SslCredentials. More... | |
| struct | SslServerCredentialsOptions |
| Options to create ServerCredentials with SSL. More... | |
| class | Status |
| Did it work? If it didn't, why? More... | |
| class | string_ref |
| This class is a non owning reference to a string. More... | |
| class | StubOptions |
| class | thread |
| class | TimePoint |
| class | TimePoint< gpr_timespec > |
| class | TimePoint< std::chrono::system_clock::time_point > |
| class | unique_lock |
| class | UnknownMethodHandler |
| class | WriteOptions |
| Per-message write options. More... | |
| class | WriterInterface |
| An interface that can be fed a sequence of messages of type W. More... | |
Typedefs | |
| typedef ServerAsyncReaderWriter< ByteBuffer, ByteBuffer > | GenericServerAsyncReaderWriter |
| typedef ClientAsyncReaderWriter< ByteBuffer, ByteBuffer > | GenericClientAsyncReaderWriter |
| typedef std::string | string |
| typedef std::pair< grpc::string_ref, grpc::string_ref > | AuthProperty |
Enumerations | |
| enum | StatusCode { OK = 0, CANCELLED = 1, UNKNOWN = 2, INVALID_ARGUMENT = 3, DEADLINE_EXCEEDED = 4, NOT_FOUND = 5, ALREADY_EXISTS = 6, PERMISSION_DENIED = 7, UNAUTHENTICATED = 16, RESOURCE_EXHAUSTED = 8, FAILED_PRECONDITION = 9, ABORTED = 10, OUT_OF_RANGE = 11, UNIMPLEMENTED = 12, INTERNAL = 13, UNAVAILABLE = 14, DATA_LOSS = 15, DO_NOT_USE = -1 } |
Functions | |
| std::shared_ptr< Channel > | CreateChannel (const grpc::string &target, const std::shared_ptr< ChannelCredentials > &creds) |
| Create a new Channel pointing to target. More... | |
| std::shared_ptr< Channel > | CreateCustomChannel (const grpc::string &target, const std::shared_ptr< ChannelCredentials > &creds, const ChannelArguments &args) |
| Create a new custom Channel pointing to target. More... | |
| std::shared_ptr< ChannelCredentials > | GoogleDefaultCredentials () |
| Builds credentials with reasonable defaults. More... | |
| std::shared_ptr< ChannelCredentials > | SslCredentials (const SslCredentialsOptions &options) |
| Builds SSL Credentials given SSL specific options. More... | |
| std::shared_ptr< CallCredentials > | GoogleComputeEngineCredentials () |
| Builds credentials for use when running in GCE. More... | |
| std::shared_ptr< CallCredentials > | ServiceAccountJWTAccessCredentials (const grpc::string &json_key, long token_lifetime_seconds) |
| Builds Service Account JWT Access credentials. More... | |
| std::shared_ptr< CallCredentials > | GoogleRefreshTokenCredentials (const grpc::string &json_refresh_token) |
| Builds refresh token credentials. More... | |
| std::shared_ptr< CallCredentials > | AccessTokenCredentials (const grpc::string &access_token) |
| Builds access token credentials. More... | |
| std::shared_ptr< CallCredentials > | GoogleIAMCredentials (const grpc::string &authorization_token, const grpc::string &authority_selector) |
| Builds IAM credentials. More... | |
| std::shared_ptr< ChannelCredentials > | CompositeChannelCredentials (const std::shared_ptr< ChannelCredentials > &channel_creds, const std::shared_ptr< CallCredentials > &call_creds) |
| Combines a channel credentials and a call credentials into a composite channel credentials. More... | |
| std::shared_ptr< CallCredentials > | CompositeCallCredentials (const std::shared_ptr< CallCredentials > &creds1, const std::shared_ptr< CallCredentials > &creds2) |
| Combines two call credentials objects into a composite call credentials. More... | |
| std::shared_ptr< ChannelCredentials > | InsecureChannelCredentials () |
| Credentials for an unencrypted, unauthenticated channel. More... | |
| std::shared_ptr< CallCredentials > | MetadataCredentialsFromPlugin (std::unique_ptr< MetadataCredentialsPlugin > plugin) |
| std::shared_ptr< ServerCredentials > | SslServerCredentials (const SslServerCredentialsOptions &options) |
| Builds SSL ServerCredentials given SSL specific options. More... | |
| std::shared_ptr< ServerCredentials > | InsecureServerCredentials () |
| Builds insecure server credentials. More... | |
| void | FillMetadataMap (grpc_metadata_array *arr, std::multimap< grpc::string_ref, grpc::string_ref > *metadata) |
| grpc_metadata * | FillMetadataArray (const std::multimap< grpc::string, grpc::string > &metadata) |
| template<class InputMessage , class OutputMessage > | |
| Status | BlockingUnaryCall (ChannelInterface *channel, const RpcMethod &method, ClientContext *context, const InputMessage &request, OutputMessage *result) |
| std::shared_ptr< const AuthContext > | CreateAuthContext (grpc_call *call) |
| bool | operator== (string_ref x, string_ref y) |
| bool | operator!= (string_ref x, string_ref y) |
| bool | operator< (string_ref x, string_ref y) |
| bool | operator<= (string_ref x, string_ref y) |
| bool | operator> (string_ref x, string_ref y) |
| bool | operator>= (string_ref x, string_ref y) |
| std::ostream & | operator<< (std::ostream &out, const string_ref &string) |
| void | Timepoint2Timespec (const std::chrono::system_clock::time_point &from, gpr_timespec *to) |
| void | TimepointHR2Timespec (const std::chrono::high_resolution_clock::time_point &from, gpr_timespec *to) |
| std::chrono::system_clock::time_point | Timespec2Timepoint (gpr_timespec t) |
Variables | |
| CoreCodegenInterface * | g_core_codegen_interface |
| GrpcLibraryInterface * | g_glip |
| Initialized by grpc::GrpcLibraryInitializer from <grpc++/impl/grpc_library.h> More... | |
| typedef std::pair<grpc::string_ref, grpc::string_ref> grpc::AuthProperty |
| typedef std::string grpc::string |
| enum grpc::StatusCode |
| Enumerator | |
|---|---|
| OK |
Not an error; returned on success. |
| CANCELLED |
The operation was cancelled (typically by the caller). |
| UNKNOWN |
Unknown error. An example of where this error may be returned is if a Status value received from another address space belongs to an error-space that is not known in this address space. Also errors raised by APIs that do not return enough error information may be converted to this error. |
| INVALID_ARGUMENT |
Client specified an invalid argument. Note that this differs from FAILED_PRECONDITION. INVALID_ARGUMENT indicates arguments that are problematic regardless of the state of the system (e.g., a malformed file name). |
| DEADLINE_EXCEEDED |
Deadline expired before operation could complete. For operations that change the state of the system, this error may be returned even if the operation has completed successfully. For example, a successful response from a server could have been delayed long enough for the deadline to expire. |
| NOT_FOUND |
Some requested entity (e.g., file or directory) was not found. |
| ALREADY_EXISTS |
Some entity that we attempted to create (e.g., file or directory) already exists. |
| PERMISSION_DENIED |
The caller does not have permission to execute the specified operation. PERMISSION_DENIED must not be used for rejections caused by exhausting some resource (use RESOURCE_EXHAUSTED instead for those errors). PERMISSION_DENIED must not be used if the caller can not be identified (use UNAUTHENTICATED instead for those errors). |
| UNAUTHENTICATED |
The request does not have valid authentication credentials for the operation. |
| RESOURCE_EXHAUSTED |
Some resource has been exhausted, perhaps a per-user quota, or perhaps the entire file system is out of space. |
| FAILED_PRECONDITION |
Operation was rejected because the system is not in a state required for the operation's execution. For example, directory to be deleted may be non-empty, an rmdir operation is applied to a non-directory, etc. A litmus test that may help a service implementor in deciding between FAILED_PRECONDITION, ABORTED, and UNAVAILABLE: (a) Use UNAVAILABLE if the client can retry just the failing call. (b) Use ABORTED if the client should retry at a higher-level (e.g., restarting a read-modify-write sequence). (c) Use FAILED_PRECONDITION if the client should not retry until the system state has been explicitly fixed. E.g., if an "rmdir" fails because the directory is non-empty, FAILED_PRECONDITION should be returned since the client should not retry unless they have first fixed up the directory by deleting files from it. (d) Use FAILED_PRECONDITION if the client performs conditional REST Get/Update/Delete on a resource and the resource on the server does not match the condition. E.g., conflicting read-modify-write on the same resource. |
| ABORTED |
The operation was aborted, typically due to a concurrency issue like sequencer check failures, transaction aborts, etc. See litmus test above for deciding between FAILED_PRECONDITION, ABORTED, and UNAVAILABLE. |
| OUT_OF_RANGE |
Operation was attempted past the valid range. E.g., seeking or reading past end of file. Unlike INVALID_ARGUMENT, this error indicates a problem that may be fixed if the system state changes. For example, a 32-bit file system will generate INVALID_ARGUMENT if asked to read at an offset that is not in the range [0,2^32-1], but it will generate OUT_OF_RANGE if asked to read from an offset past the current file size. There is a fair bit of overlap between FAILED_PRECONDITION and OUT_OF_RANGE. We recommend using OUT_OF_RANGE (the more specific error) when it applies so that callers who are iterating through a space can easily look for an OUT_OF_RANGE error to detect when they are done. |
| UNIMPLEMENTED |
Operation is not implemented or not supported/enabled in this service. |
| INTERNAL |
Internal errors. Means some invariants expected by underlying System has been broken. If you see one of these errors, Something is very broken. |
| UNAVAILABLE |
The service is currently unavailable. This is a most likely a transient condition and may be corrected by retrying with a backoff. See litmus test above for deciding between FAILED_PRECONDITION, ABORTED, and UNAVAILABLE. |
| DATA_LOSS |
Unrecoverable data loss or corruption. |
| DO_NOT_USE |
Force users to include a default branch: |
| std::shared_ptr<CallCredentials> grpc::AccessTokenCredentials | ( | const grpc::string & | access_token | ) |
Builds access token credentials.
access_token is an oauth2 access token that was fetched using an out of band mechanism.
| Status grpc::BlockingUnaryCall | ( | ChannelInterface * | channel, |
| const RpcMethod & | method, | ||
| ClientContext * | context, | ||
| const InputMessage & | request, | ||
| OutputMessage * | result | ||
| ) |
| std::shared_ptr<CallCredentials> grpc::CompositeCallCredentials | ( | const std::shared_ptr< CallCredentials > & | creds1, |
| const std::shared_ptr< CallCredentials > & | creds2 | ||
| ) |
Combines two call credentials objects into a composite call credentials.
| std::shared_ptr<ChannelCredentials> grpc::CompositeChannelCredentials | ( | const std::shared_ptr< ChannelCredentials > & | channel_creds, |
| const std::shared_ptr< CallCredentials > & | call_creds | ||
| ) |
Combines a channel credentials and a call credentials into a composite channel credentials.
| std::shared_ptr<const AuthContext> grpc::CreateAuthContext | ( | grpc_call * | call | ) |
| std::shared_ptr<Channel> grpc::CreateChannel | ( | const grpc::string & | target, |
| const std::shared_ptr< ChannelCredentials > & | creds | ||
| ) |
Create a new Channel pointing to target.
| target | The URI of the endpoint to connect to. |
| creds | Credentials to use for the created channel. If it does not hold an object or is invalid, a lame channel is returned. |
| args | Options for channel creation. |
| std::shared_ptr<Channel> grpc::CreateCustomChannel | ( | const grpc::string & | target, |
| const std::shared_ptr< ChannelCredentials > & | creds, | ||
| const ChannelArguments & | args | ||
| ) |
Create a new custom Channel pointing to target.
| target | The URI of the endpoint to connect to. |
| creds | Credentials to use for the created channel. If it does not hold an object or is invalid, a lame channel is returned. |
| args | Options for channel creation. |
|
inline |
|
inline |
| std::shared_ptr<CallCredentials> grpc::GoogleComputeEngineCredentials | ( | ) |
Builds credentials for use when running in GCE.
| std::shared_ptr<ChannelCredentials> grpc::GoogleDefaultCredentials | ( | ) |
Builds credentials with reasonable defaults.
| std::shared_ptr<CallCredentials> grpc::GoogleIAMCredentials | ( | const grpc::string & | authorization_token, |
| const grpc::string & | authority_selector | ||
| ) |
Builds IAM credentials.
| std::shared_ptr<CallCredentials> grpc::GoogleRefreshTokenCredentials | ( | const grpc::string & | json_refresh_token | ) |
Builds refresh token credentials.
json_refresh_token is the JSON string containing the refresh token along with a client_id and client_secret.
| std::shared_ptr<ChannelCredentials> grpc::InsecureChannelCredentials | ( | ) |
Credentials for an unencrypted, unauthenticated channel.
| std::shared_ptr<ServerCredentials> grpc::InsecureServerCredentials | ( | ) |
Builds insecure server credentials.
| std::shared_ptr<CallCredentials> grpc::MetadataCredentialsFromPlugin | ( | std::unique_ptr< MetadataCredentialsPlugin > | plugin | ) |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
| std::shared_ptr<CallCredentials> grpc::ServiceAccountJWTAccessCredentials | ( | const grpc::string & | json_key, |
| long | token_lifetime_seconds | ||
| ) |
Builds Service Account JWT Access credentials.
json_key is the JSON key string containing the client's private key. token_lifetime_seconds is the lifetime in seconds of each Json Web Token (JWT) created with this credentials. It should not exceed grpc_max_auth_token_lifetime or will be cropped to this value.
| std::shared_ptr<ChannelCredentials> grpc::SslCredentials | ( | const SslCredentialsOptions & | options | ) |
Builds SSL Credentials given SSL specific options.
| std::shared_ptr<ServerCredentials> grpc::SslServerCredentials | ( | const SslServerCredentialsOptions & | options | ) |
Builds SSL ServerCredentials given SSL specific options.
| void grpc::Timepoint2Timespec | ( | const std::chrono::system_clock::time_point & | from, |
| gpr_timespec * | to | ||
| ) |
| void grpc::TimepointHR2Timespec | ( | const std::chrono::high_resolution_clock::time_point & | from, |
| gpr_timespec * | to | ||
| ) |
| std::chrono::system_clock::time_point grpc::Timespec2Timepoint | ( | gpr_timespec | t | ) |
| CoreCodegenInterface * grpc::g_core_codegen_interface |
| GrpcLibraryInterface* grpc::g_glip |
Initialized by grpc::GrpcLibraryInitializer from <grpc++/impl/grpc_library.h>
1.8.11