Couchbase C Client  3.2.2
Asynchronous C Client for Couchbase
error.h File Reference

Definition of all of the error codes used by libcouchbase. More...

Go to the source code of this file.

Macros

#define LCB_XERROR(X)
 
#define X(n, v, cls, f, s)
 
#define LCB_ERROR_IS_NETWORK(e)
 if the error is a result of a network condition
 
#define LCB_ERROR_IS_SUBDOC(e)
 
#define LCB_ERROR_IS_TRANSIENT(e)
 
#define LCB_ERROR_IS_FATAL(e)
 
#define LCB_ERROR_IS_INPUT(e)
 
#define LCB_XRETRY_REASON(X)
 
#define X(n, c, nir, ar)
 

Typedefs

typedef struct lcb_KEY_VALUE_ERROR_CONTEXT_ lcb_KEY_VALUE_ERROR_CONTEXT
 
typedef struct lcb_QUERY_ERROR_CONTEXT_ lcb_QUERY_ERROR_CONTEXT
 
typedef struct lcb_ANALYTICS_ERROR_CONTEXT_ lcb_ANALYTICS_ERROR_CONTEXT
 
typedef struct lcb_VIEW_ERROR_CONTEXT_ lcb_VIEW_ERROR_CONTEXT
 
typedef struct lcb_SEARCH_ERROR_CONTEXT_ lcb_SEARCH_ERROR_CONTEXT
 
typedef struct lcb_HTTP_ERROR_CONTEXT_ lcb_HTTP_ERROR_CONTEXT
 
typedef lcb_STATUS(* lcb_errmap_callback) (lcb_INSTANCE *instance, lcb_U16 bincode)
 Callback for error mappings. More...
 
typedef struct lcb_RETRY_REQUEST_ lcb_RETRY_REQUEST
 
typedef lcb_RETRY_ACTION(* lcb_RETRY_STRATEGY) (lcb_RETRY_REQUEST *req, lcb_RETRY_REASON reason)
 

Enumerations

enum  lcb_ERROR_TYPE
 
enum  lcb_ERROR_FLAGS
 
enum  lcb_STATUS
 Error codes returned by the library. More...
 
enum  lcb_RETRY_REASON
 

Functions

lcb_STATUS lcb_errctx_kv_rc (const lcb_KEY_VALUE_ERROR_CONTEXT *ctx)
 
lcb_STATUS lcb_errctx_kv_status_code (const lcb_KEY_VALUE_ERROR_CONTEXT *ctx, uint16_t *status_code)
 
lcb_STATUS lcb_errctx_kv_opaque (const lcb_KEY_VALUE_ERROR_CONTEXT *ctx, uint32_t *opaque)
 
lcb_STATUS lcb_errctx_kv_cas (const lcb_KEY_VALUE_ERROR_CONTEXT *ctx, uint64_t *cas)
 
lcb_STATUS lcb_errctx_kv_key (const lcb_KEY_VALUE_ERROR_CONTEXT *ctx, const char **key, size_t *key_len)
 
lcb_STATUS lcb_errctx_kv_bucket (const lcb_KEY_VALUE_ERROR_CONTEXT *ctx, const char **bucket, size_t *bucket_len)
 
lcb_STATUS lcb_errctx_kv_collection (const lcb_KEY_VALUE_ERROR_CONTEXT *ctx, const char **collection, size_t *collection_len)
 
lcb_STATUS lcb_errctx_kv_scope (const lcb_KEY_VALUE_ERROR_CONTEXT *ctx, const char **scope, size_t *scope_len)
 
lcb_STATUS lcb_errctx_kv_context (const lcb_KEY_VALUE_ERROR_CONTEXT *ctx, const char **context, size_t *context_len)
 
lcb_STATUS lcb_errctx_kv_ref (const lcb_KEY_VALUE_ERROR_CONTEXT *ctx, const char **ref, size_t *ref_len)
 
lcb_STATUS lcb_errctx_kv_endpoint (const lcb_KEY_VALUE_ERROR_CONTEXT *ctx, const char **endpoint, size_t *endpoint_len)
 
lcb_STATUS lcb_errctx_query_rc (const lcb_QUERY_ERROR_CONTEXT *ctx)
 
lcb_STATUS lcb_errctx_query_first_error_code (const lcb_QUERY_ERROR_CONTEXT *ctx, uint32_t *code)
 
lcb_STATUS lcb_errctx_query_first_error_message (const lcb_QUERY_ERROR_CONTEXT *ctx, const char **message, size_t *message_len)
 
lcb_STATUS lcb_errctx_query_statement (const lcb_QUERY_ERROR_CONTEXT *ctx, const char **statement, size_t *statement_len)
 
lcb_STATUS lcb_errctx_query_client_context_id (const lcb_QUERY_ERROR_CONTEXT *ctx, const char **id, size_t *id_len)
 
lcb_STATUS lcb_errctx_query_query_params (const lcb_QUERY_ERROR_CONTEXT *ctx, const char **params, size_t *params_len)
 
lcb_STATUS lcb_errctx_query_http_response_code (const lcb_QUERY_ERROR_CONTEXT *ctx, uint32_t *code)
 
lcb_STATUS lcb_errctx_query_http_response_body (const lcb_QUERY_ERROR_CONTEXT *ctx, const char **body, size_t *body_len)
 
lcb_STATUS lcb_errctx_query_endpoint (const lcb_QUERY_ERROR_CONTEXT *ctx, const char **endpoint, size_t *endpoint_len)
 
lcb_STATUS lcb_errctx_analytics_rc (const lcb_ANALYTICS_ERROR_CONTEXT *ctx)
 
lcb_STATUS lcb_errctx_analytics_first_error_code (const lcb_ANALYTICS_ERROR_CONTEXT *ctx, uint32_t *code)
 
lcb_STATUS lcb_errctx_analytics_first_error_message (const lcb_ANALYTICS_ERROR_CONTEXT *ctx, const char **message, size_t *message_len)
 
lcb_STATUS lcb_errctx_analytics_statement (const lcb_ANALYTICS_ERROR_CONTEXT *ctx, const char **statement, size_t *statement_len)
 
lcb_STATUS lcb_errctx_analytics_query_params (const lcb_ANALYTICS_ERROR_CONTEXT *ctx, const char **query_params, size_t *query_params_len)
 
lcb_STATUS lcb_errctx_analytics_client_context_id (const lcb_ANALYTICS_ERROR_CONTEXT *ctx, const char **id, size_t *id_len)
 
lcb_STATUS lcb_errctx_analytics_http_response_code (const lcb_ANALYTICS_ERROR_CONTEXT *ctx, uint32_t *code)
 
lcb_STATUS lcb_errctx_analytics_http_response_body (const lcb_ANALYTICS_ERROR_CONTEXT *ctx, const char **body, size_t *body_len)
 
lcb_STATUS lcb_errctx_analytics_endpoint (const lcb_ANALYTICS_ERROR_CONTEXT *ctx, const char **endpoint, size_t *endpoint_len)
 
lcb_STATUS lcb_errctx_view_rc (const lcb_VIEW_ERROR_CONTEXT *ctx)
 
lcb_STATUS lcb_errctx_view_first_error_code (const lcb_VIEW_ERROR_CONTEXT *ctx, const char **code, size_t *code_len)
 
lcb_STATUS lcb_errctx_view_first_error_message (const lcb_VIEW_ERROR_CONTEXT *ctx, const char **message, size_t *message_len)
 
lcb_STATUS lcb_errctx_view_design_document (const lcb_VIEW_ERROR_CONTEXT *ctx, const char **name, size_t *name_len)
 
lcb_STATUS lcb_errctx_view_view (const lcb_VIEW_ERROR_CONTEXT *ctx, const char **name, size_t *name_len)
 
lcb_STATUS lcb_errctx_view_query_params (const lcb_VIEW_ERROR_CONTEXT *ctx, const char **params, size_t *params_len)
 
lcb_STATUS lcb_errctx_view_http_response_code (const lcb_VIEW_ERROR_CONTEXT *ctx, uint32_t *code)
 
lcb_STATUS lcb_errctx_view_http_response_body (const lcb_VIEW_ERROR_CONTEXT *ctx, const char **body, size_t *body_len)
 
lcb_STATUS lcb_errctx_view_endpoint (const lcb_VIEW_ERROR_CONTEXT *ctx, const char **endpoint, size_t *endpoint_len)
 
lcb_STATUS lcb_errctx_search_rc (const lcb_SEARCH_ERROR_CONTEXT *ctx)
 
lcb_STATUS lcb_errctx_search_error_message (const lcb_SEARCH_ERROR_CONTEXT *ctx, const char **message, size_t *message_len)
 
lcb_STATUS lcb_errctx_search_index_name (const lcb_SEARCH_ERROR_CONTEXT *ctx, const char **name, size_t *name_len)
 
lcb_STATUS lcb_errctx_search_query (const lcb_SEARCH_ERROR_CONTEXT *ctx, const char **query, size_t *query_len)
 
lcb_STATUS lcb_errctx_search_params (const lcb_SEARCH_ERROR_CONTEXT *ctx, const char **params, size_t *params_len)
 
lcb_STATUS lcb_errctx_search_http_response_code (const lcb_SEARCH_ERROR_CONTEXT *ctx, uint32_t *code)
 
lcb_STATUS lcb_errctx_search_http_response_body (const lcb_SEARCH_ERROR_CONTEXT *ctx, const char **body, size_t *body_len)
 
lcb_STATUS lcb_errctx_search_endpoint (const lcb_SEARCH_ERROR_CONTEXT *ctx, const char **endpoint, size_t *endpoint_len)
 
lcb_STATUS lcb_errctx_http_rc (const lcb_HTTP_ERROR_CONTEXT *ctx)
 
lcb_STATUS lcb_errctx_http_path (const lcb_HTTP_ERROR_CONTEXT *ctx, const char **path, size_t *path_len)
 
lcb_STATUS lcb_errctx_http_response_code (const lcb_HTTP_ERROR_CONTEXT *ctx, uint32_t *code)
 
lcb_STATUS lcb_errctx_http_response_body (const lcb_HTTP_ERROR_CONTEXT *ctx, const char **body, size_t *body_len)
 
lcb_STATUS lcb_errctx_http_endpoint (const lcb_HTTP_ERROR_CONTEXT *ctx, const char **endpoint, size_t *endpoint_len)
 
uint32_t lcb_error_flags (lcb_STATUS err)
 
Get error categories for a specific code More...
 
LCB_INTERNAL_API const char * lcb_strerror_short (lcb_STATUS error)
 Get a shorter textual description of an error message. More...
 
LCB_INTERNAL_API const char * lcb_strerror_long (lcb_STATUS error)
 Get a longer textual description of an error message.
 
lcb_STATUS lcb_errmap_default (lcb_INSTANCE *instance, lcb_U16 code)
 
This may be used in conjunction with the errmap callback if it wishes to fallback for default behavior for the given code. More...
 
lcb_errmap_callback lcb_set_errmap_callback (lcb_INSTANCE *instance, lcb_errmap_callback)
 
int lcb_retry_reason_allows_non_idempotent_retry (lcb_RETRY_REASON code)
 
int lcb_retry_reason_is_always_retry (lcb_RETRY_REASON code)
 
int lcb_retry_request_is_idempotent (lcb_RETRY_REQUEST *req)
 
int lcb_retry_request_retry_attempts (lcb_RETRY_REQUEST *req)
 
void * lcb_retry_request_operation_cookie (lcb_RETRY_REQUEST *req)
 
lcb_STATUS lcb_retry_strategy (lcb_INSTANCE *instance, lcb_RETRY_STRATEGY strategy)
 Set the global retry strategy. More...
 

Detailed Description

Definition of all of the error codes used by libcouchbase.