Couchbase C Client  3.3.12
Asynchronous C Client for Couchbase
cntl.h File Reference

Command codes for libcouchbase. More...

#include "cntl-private.h"

Go to the source code of this file.

Data Structures

struct  lcb_cntl_vbinfo_t
 Structure containing mapping information for a key. More...
 
struct  lcb_cntl_vbinfo_t.v.v0
 v0 More...
 

Macros

#define LCB_CNTL_OP_TIMEOUT
 Operation Timeout.
 
#define LCB_CNTL_VIEW_TIMEOUT
 Views Timeout This is the I/O timeout for HTTP requests issues with LCB_HTTP_TYPE_VIEWS.
 
#define LCB_CNTL_QUERY_TIMEOUT
 N1QL Timeout This is the I/O timeout for N1QL queries, issued via lcb_n1ql_query()
 
#define LCB_CNTL_BUCKETNAME
 Get the name of the bucket This returns the name of the bucket this instance is connected to, or NULL if not yet connected to a bucket.
 
#define LCB_CNTL_BUCKETTYPE
 Get the bucket type.
 
#define LCB_CNTL_HANDLETYPE
 Get the handle type.
 
#define LCB_CNTL_VBCONFIG
 Get the vBucket handle.
 
#define LCB_CNTL_IOPS
 Get the iops implementation instance.
 
#define LCB_CNTL_VBMAP
 Get the vBucket ID for a given key, based on the current configuration.
 
#define LCB_CNTL_IP6POLICY
 IPv4/IPv6 selection policy.
 
#define LCB_CNTL_CONFERRTHRESH
 Configuration error threshold.
 
#define LCB_CNTL_DURABILITY_TIMEOUT
 Default timeout for lcb_durability_poll()
 
#define LCB_CNTL_DURABILITY_INTERVAL
 Polling grace interval for lcb_durability_poll()
 
#define LCB_CNTL_HTTP_TIMEOUT
 Timeout for otherwise unspecified HTTP requests.
 
#define LCB_CNTL_IOPS_DLOPEN_DEBUG
 Print verbose plugin load information to console.
 
#define LCB_CNTL_CONFIGURATION_TIMEOUT
 Initial bootstrap timeout.
 
#define LCB_CNTL_RANDOMIZE_BOOTSTRAP_HOSTS
 Randomize order of bootstrap nodes.
 
#define LCB_CNTL_CONFIG_CACHE_LOADED
 Determine if file-based configuration has been loaded.
 
#define LCB_CNTL_FORCE_SASL_MECH
 Force a specific SASL mechanism.
 
#define LCB_CNTL_MAX_REDIRECTS
 Maximum number of HTTP redirects to follow Set how many redirects the library should follow for the single request.
 
#define LCB_CNTL_CONFDELAY_THRESH
 Refresh Throttling.
 
#define LCB_CNTL_CONFIG_TRANSPORT
 Get the transport used to fetch cluster configuration.
 
#define LCB_CNTL_CONFIG_NODE_TIMEOUT
 Per-node configuration timeout.
 
#define LCB_CNTL_HTCONFIG_IDLE_TIMEOUT
 Idling/Persistence for HTTP bootstrap.
 
#define LCB_CNTL_CHANGESET
 Get the current SCM changeset for the library binary.
 
#define LCB_CNTL_CONFIGCACHE
 File used for the configuration cache.
 
#define LCB_CNTL_CONFIGCACHE_RO
 File used for read-only configuration cache.
 
#define LCB_CNTL_SSL_MODE
 Get SSL Mode.
 
#define LCB_CNTL_SSL_CERT
 Get SSL Certificate path.
 
#define LCB_CNTL_SSL_KEY
 Get SSL private key path.
 
#define LCB_CNTL_SSL_TRUSTSTORE
 Get SSL trust store path.
 
#define LCB_CNTL_SSL_CACERT
 Alias for LCB_CNTL_SSL_CERT for backward compatibility.
 
#define LCB_RETRYOPT_CREATE(mode, policy)
 Create a retry setting value.
 
#define LCB_RETRYOPT_GETMODE(u)
 Get mode from retry setting value.
 
#define LCB_RETRYOPT_GETPOLICY(u)
 Get policy from retry setting value.
 
#define LCB_CNTL_RETRYMODE
 Set retry policies.
 
#define LCB_CNTL_HTCONFIG_URLTYPE
 Set the URL selection mode.
 
#define LCB_CNTL_SYNCDESTROY
 Determines whether to run the event loop internally within lcb_destroy() until no more I/O resources remain for the library.
 
#define LCB_CNTL_CONLOGGER_LEVEL
 Sets the logging level for the console logger.
 
#define LCB_CNTL_CONLOGGER_FP
 Sets the output file (as a FILE*) for the console logger.
 
#define LCB_CNTL_DETAILED_ERRCODES
 Sets the behavior for reporting network errors.
 
#define LCB_CNTL_RETRY_INTERVAL
 Sets the interval at which the retry queue will attempt to resend a failed operation.
 
#define LCB_CNTL_RETRY_NMV_IMM
 Whether commands are retried immediately upon receipt of not-my-vbucket replies.
 
#define LCB_CNTL_HTTP_POOLSIZE
 Set the maximum pool size for pooled http (view request) sockets.
 
#define LCB_CNTL_HTTP_REFRESH_CONFIG_ON_ERROR
 Determine whether or not a new configuration should be received when an error is received over the HTTP API (i.e.
 
#define LCB_CNTL_SCHED_IMPLICIT_FLUSH
 Set the behavior of the lcb_sched_leave() API call.
 
#define LCB_CNTL_ENABLE_MUTATION_TOKENS
 Request the server to return an additional 16 bytes of data for each mutation operation.
 
#define LCB_CNTL_MUTATION_TOKENS_SUPPORTED
 This read-only property determines if the mutation token mechanism is supported on the cluster itself.
 
#define LCB_CNTL_RESET_TIMEOUT_ON_WAIT
 This setting determines if calls to lcb_wait() and lcb_wait() will reset the timeout of pending operations to the time that lcb_wait() was called, rather than having the operation maintain the time of the call which scheduled it.
 
#define LCB_CNTL_QUERY_CLEARACHE
 Clears the internal prepared statement cache for N1QL.
 
#define LCB_CNTL_CLIENT_STRING
 Sets additional text for negotiation.
 
#define LCB_CNTL_BUCKET_CRED
 Set credentials for a bucket.
 
#define LCB_CNTL_RETRY_NMV_INTERVAL
 Set the amount of time the client should wait before retrying a not-my-vbucket response packet.
 
#define LCB_CNTL_READ_CHUNKSIZE
 Limit the number of bytes to be read (and thereby processed) during I/O read operations.
 
#define LCB_CNTL_SELECT_BUCKET
 Enable/Disable sending the SELECT_BUCKET command after authentication.
 
#define LCB_CNTL_TCP_KEEPALIVE
 Enable/Disable setting the TCP_KEEPALIVE option on created sockets.
 
#define LCB_CNTL_CONFIG_POLL_INTERVAL
 Set the amount of time to wait in between polling for a new configuration.
 
#define LCB_CNTL_LOG_REDACTION
 Once redaction is enabled, anything at ERROR, WARN and INFO will wrap sensitive information with special tags, for further processing with the goal to remove or encrypt that information.
 
#define LCB_CNTL_ENABLE_TRACING
 Activate/deactivate end-to-end tracing.
 
#define LCB_CNTL_TRACING_ORPHANED_QUEUE_FLUSH_INTERVAL
 Flush interval for orphaned spans queue in default tracer.
 
#define LCB_CNTL_TRACING_ORPHANED_QUEUE_SIZE
 Size of orphaned spans queue in default tracer.
 
#define LCB_CNTL_TRACING_THRESHOLD_QUEUE_FLUSH_INTERVAL
 Flush interval for spans with total time over threshold in default tracer.
 
#define LCB_CNTL_TRACING_THRESHOLD_QUEUE_SIZE
 Size of threshold queue in default tracer.
 
#define LCB_CNTL_TRACING_THRESHOLD_KV
 Minimum time for the tracing span of KV service to be considered by threshold tracer.
 
#define LCB_CNTL_TRACING_THRESHOLD_QUERY
 Minimum time for the tracing span of N1QL service to be considered by threshold tracer.
 
#define LCB_CNTL_TRACING_THRESHOLD_VIEW
 Minimum time for the tracing span of VIEW service to be considered by threshold tracer.
 
#define LCB_CNTL_TRACING_THRESHOLD_SEARCH
 Minimum time for the tracing span of FTS service to be considered by threshold tracer.
 
#define LCB_CNTL_TRACING_THRESHOLD_ANALYTICS
 Minimum time for the tracing span of ANALYTICS service to be considered by threshold tracer.
 
#define LCB_CNTL_COMPRESSION_OPTS
 Control how the library handles compression and deflation to and from the server.
 
#define LCB_CNTL_COMPRESSION_MIN_SIZE
 Minimum size of the document payload to be compressed when compression enabled.
 
#define LCB_CNTL_COMPRESSION_MIN_RATIO
 Minimum compression ratio (compressed / original) of the compressed payload to allow sending it to cluster.
 
#define LCB_CNTL_NETWORK
 Select type of network (alternative addresses).
 
#define LCB_CNTL_HTTP_POOL_TIMEOUT
 The amount of time the pool should wait before closing idle connections.
 
#define LCB_CNTL_ENABLE_COLLECTIONS
 
#define LCB_CNTL_ENABLE_DURABLE_WRITE
 
#define LCB_CNTL_PERSISTENCE_TIMEOUT_FLOOR
 
#define LCB_CNTL_ALLOW_STATIC_CONFIG
 
#define LCB_CNTL_ANALYTICS_TIMEOUT
 Analytics Timeout This is the global I/O timeout for Analytics queries, issued via lcb_analytics()
 
#define LCB_CNTL_ENABLE_UNORDERED_EXECUTION
 Tell the server that the library supports reordering the execution of the commands.
 
#define LCB_CNTL_SEARCH_TIMEOUT
 Search Timeout This is the global I/O timeout for Search queries, issued via lcb_search()
 
#define LCB_CNTL_ENABLE_ERRMAP
 Enable/Disable the Error Map feature.
 
#define LCB_CNTL_OP_METRICS_FLUSH_INTERVAL
 Flush interval for the per-operation metrics to be output to the logs.
 
#define LCB_CNTL_ENABLE_OP_METRICS
 Enable/disable per-operation metrics collection.
 
#define LCB_CNTL__MAX
 This is not a command, but rather an indicator of the last item.
 
Modes

Modes for the lcb_cntl() mode argument

#define LCB_CNTL_SET
 Modify a setting.
 
#define LCB_CNTL_GET
 Retrieve a setting.
 
Logging

Verbose logging may be enabled by default using the environment variable LCB_LOGLEVEL and setting it to a number > 1; higher values produce more verbose output.

The maximum level is 5.

You may also install your own logger using lcb_cntl() and the LCB_CNTL_LOGGER constant. Note that the logger functions will not be called rapidly from within hot paths.

#define LCB_CNTL_LOGGER
 Access the lcb_LOGGER structure.
 

Typedefs

typedef const char * lcb_BUCKETCRED[2]
 

Enumerations

enum  lcb_ipv6_t
 Modes for handling IPv6 in the IO layer. More...
 
enum  lcb_SSLOPTS
 SSL options. More...
 
enum  lcb_RETRYMODEOPTS
 Select retry mode to manipulate. More...
 
enum  lcb_RETRYCMDOPTS
 
enum  lcb_HTCONFIG_URLTYPE
 Enumeration representing various URL forms to use for the configuration stream. More...
 
enum  lcbtrace_THRESHOLDOPTS
 
enum  lcb_COMPRESSOPTS
 Options for how to handle compression. More...
 

Detailed Description

Command codes for libcouchbase.

These codes may be passed to 'lcb_cntl'.

Note that the constant values are also public API; thus allowing forwards and backwards compatibility.