|
lcbvb_CONFIG * | lcbvb_create (void) |
| Allocate a new config This can be used to create new config object and load it with a JSON config, optionally retrieving the error code. More...
|
|
lcbvb_CONFIG * | lcbvb_parse_json (const char *data) |
|
int | lcbvb_load_json (lcbvb_CONFIG *vbc, const char *data) |
|
char * | lcbvb_save_json (lcbvb_CONFIG *vbc) |
| Serialize the current config as a JSON string. More...
|
|
const char * | lcbvb_get_error (const lcbvb_CONFIG *vbc) |
| Return a string indicating why parsing the configuration failed. More...
|
|
void | lcbvb_replace_host (lcbvb_CONFIG *cfg, const char *hostname) |
| Replace hostname placeholders with specific host string This function shall replace hostname placeholists with the actual host string specified in hoststr . More...
|
|
void | lcbvb_destroy (lcbvb_CONFIG *conf) |
|
int | lcbvb_vbmaster (lcbvb_CONFIG *cfg, int vbid) |
|
int | lcbvb_vbreplica (lcbvb_CONFIG *cfg, int vbid, unsigned ix) |
|
int | lcbvb_nmv_remap (lcbvb_CONFIG *cfg, int vbid, int bad) |
|
int | lcbvb_map_key (lcbvb_CONFIG *cfg, const void *key, lcb_SIZE n, int *vbid, int *srvix) |
|
int | lcbvb_k2vb (lcbvb_CONFIG *cfg, const void *key, lcb_SIZE n) |
|
int | lcbvb_has_vbucket (lcbvb_CONFIG *vbc, int vbid, int ix) |
| uncommitted Determines if a given server index is either a master or a replica for a vbucket More...
|
|
unsigned | lcbvb_get_nservers (const lcbvb_CONFIG *cfg) |
| Get the number of servers in the bucket. Note that not all servers may actually be available. More...
|
|
unsigned | lcbvb_get_nreplicas (const lcbvb_CONFIG *cfg) |
| Get the number of replicas the bucket is configured with Note that not all replicas may necessarily be online or available. More...
|
|
lcbvb_DISTMODE | lcbvb_get_distmode (const lcbvb_CONFIG *cfg) |
| Get the distribution mode (AKA bucket type) of the bucket. More...
|
|
int | lcbvb_get_revision (const lcbvb_CONFIG *cfg) |
| Get the revision for this configuration. More...
|
|
unsigned | lcbvb_get_port (lcbvb_CONFIG *cfg, unsigned ix, lcbvb_SVCTYPE type, lcbvb_SVCMODE mode) |
| Gets the port associated with a given service of a given mode on a given server. More...
|
|
const char * | lcbvb_get_hostport (lcbvb_CONFIG *cfg, unsigned ix, lcbvb_SVCTYPE type, lcbvb_SVCMODE mode) |
| Return a string for the given service This is like lcbvb_get_port but returns a string in the form of host:port rather than the numeric port. More...
|
|
lcbvb_CONFIGDIFF * | lcbvb_compare (lcbvb_CONFIG *from, lcbvb_CONFIG *to) |
| Compare two configurations and return information on the changes. More...
|
|
void | lcbvb_free_diff (lcbvb_CONFIGDIFF *diff) |
| Free the structure returned by lcbvb_compare()
|
|
lcbvb_CHANGETYPE | lcbvb_get_changetype (lcbvb_CONFIGDIFF *diff) |
| Get a quick summary of the changes in the passed object. More...
|
|
int | lcbvb_genconfig_ex (lcbvb_CONFIG *vb, const char *name, const char *uuid, const lcbvb_SERVER *servers, unsigned nservers, unsigned nreplica, unsigned nvbuckets) |
| Generate a sample configuration. More...
|
|
int | lcbvb_genconfig (lcbvb_CONFIG *vb, unsigned nservers, unsigned nreplica, unsigned nvbuckets) |
| Generate a sample configuration used for testing. More...
|
|
void | lcbvb_make_ketama (lcbvb_CONFIG *vb) |
|
const char * | lcbvb_get_capibase (lcbvb_CONFIG *cfg, unsigned ix, lcbvb_SVCMODE mode) |
|
int | vbucket_config_parse (lcbvb_CONFIG *, vbucket_source_t, const char *) |
|
const char * | vbucket_get_error_message (lcbvb_CONFIG *) |
|
lcbvb_CONFIG * | vbucket_config_create (void) |
|
void | vbucket_config_destroy (lcbvb_CONFIG *) |
|
int | vbucket_config_get_num_replicas (lcbvb_CONFIG *) |
|
int | vbucket_config_get_num_vbuckets (lcbvb_CONFIG *) |
|
int | vbucket_config_get_num_servers (lcbvb_CONFIG *) |
|
const char * | vbucket_config_get_server (lcbvb_CONFIG *, int) |
|
const char * | vbucket_config_get_couch_api_base (lcbvb_CONFIG *, int) |
|
const char * | vbucket_config_get_rest_api_server (lcbvb_CONFIG *, int) |
|
lcbvb_DISTMODE | vbucket_config_get_distribution_type (lcbvb_CONFIG *) |
|
int | vbucket_map (lcbvb_CONFIG *, const void *, lcb_SIZE, int *, int *) |
|
int | vbucket_get_vbucket_by_key (lcbvb_CONFIG *, const void *, lcb_SIZE) |
|
int | vbucket_get_master (lcbvb_CONFIG *, int) |
|
int | vbucket_get_replica (lcbvb_CONFIG *, int, int) |
|
lcbvb_CONFIGDIFF * | vbucket_compare (lcbvb_CONFIG *, lcbvb_CONFIG *) |
|
void | vbucket_free_diff (lcbvb_CONFIGDIFF *) |
|
int | vbucket_config_get_revision (lcbvb_CONFIG *) |
|
lcbvb_CHANGETYPE | vbucket_what_changed (lcbvb_CONFIGDIFF *diff) |
|
int | vbucket_config_generate (lcbvb_CONFIG *vb, unsigned, unsigned, unsigned) |
|