CouchbaseGetBucket
Get a Couchbase bucket instance for bucket-level operations.
Syntax
couchbaseGetBucket(cacheName)Parameters
Parameter
Type
Required
Description
cacheName
String
Yes
Name of the cache configuration
Returns
Returns the Couchbase Bucket instance with access to:
Scope management
Collection access
Bucket statistics
Ping operations
View queries (legacy)
Examples
Basic Usage
Access Collections
Bucket Operations
Multiple Buckets
Bucket Statistics
Notes
Bucket name is determined by cache configuration
Bucket instance is cached and reused
Use
couchbaseGetCollection()for direct collection accessMost operations should use collection-level access
Bucket-level access is useful for management and statistics
Related Functions
couchbaseGetCluster - Get cluster connection
couchbaseGetScope - Get scope instance
couchbaseGetCollection - Get collection instance
See Also
Last updated
Was this helpful?
