GRPC Core
0.11.0.0
|
#include "src/core/client_config/client_config.h"
#include "src/core/iomgr/iomgr.h"
#include "src/core/iomgr/sockaddr.h"
Go to the source code of this file.
Data Structures | |
struct | grpc_resolver |
grpc_resolver provides grpc_client_config objects to grpc_channel objects More... | |
struct | grpc_resolver_vtable |
Macros | |
#define | GRPC_RESOLVER_REF(p, r) grpc_resolver_ref((p)) |
#define | GRPC_RESOLVER_UNREF(p, r) grpc_resolver_unref((p)) |
Typedefs | |
typedef struct grpc_resolver | grpc_resolver |
typedef struct grpc_resolver_vtable | grpc_resolver_vtable |
Functions | |
void | grpc_resolver_ref (grpc_resolver *policy) |
void | grpc_resolver_unref (grpc_resolver *policy) |
void | grpc_resolver_init (grpc_resolver *resolver, const grpc_resolver_vtable *vtable) |
void | grpc_resolver_shutdown (grpc_resolver *resolver) |
void | grpc_resolver_channel_saw_error (grpc_resolver *resolver, struct sockaddr *failing_address, int failing_address_len) |
Notification that the channel has seen an error on some address. More... | |
void | grpc_resolver_next (grpc_resolver *resolver, grpc_client_config **target_config, grpc_iomgr_closure *on_complete) |
Get the next client config. More... | |
#define GRPC_RESOLVER_REF | ( | p, | |
r | |||
) | grpc_resolver_ref((p)) |
#define GRPC_RESOLVER_UNREF | ( | p, | |
r | |||
) | grpc_resolver_unref((p)) |
typedef struct grpc_resolver grpc_resolver |
typedef struct grpc_resolver_vtable grpc_resolver_vtable |
void grpc_resolver_channel_saw_error | ( | grpc_resolver * | resolver, |
struct sockaddr * | failing_address, | ||
int | failing_address_len | ||
) |
Notification that the channel has seen an error on some address.
Can be used as a hint that re-resolution is desirable soon.
void grpc_resolver_init | ( | grpc_resolver * | resolver, |
const grpc_resolver_vtable * | vtable | ||
) |
void grpc_resolver_next | ( | grpc_resolver * | resolver, |
grpc_client_config ** | target_config, | ||
grpc_iomgr_closure * | on_complete | ||
) |
Get the next client config.
Called by the channel to fetch a new configuration. Expected to set *target_config with a new configuration, and then schedule on_complete for execution.
If resolution is fatally broken, set *target_config to NULL and schedule on_complete.
void grpc_resolver_ref | ( | grpc_resolver * | policy | ) |
void grpc_resolver_shutdown | ( | grpc_resolver * | resolver | ) |
void grpc_resolver_unref | ( | grpc_resolver * | policy | ) |