Class

Bucket

Bucket

Bucket represents a storage grouping of data within a Couchbase Server cluster.

Members

string

# name

Returns the name of this bucket.

View Source bucket.js, line 195

Methods

# collection(collectionName) → {Collection}

Gets a reference to a specific collection.

Parameters:
Name Type Description
collectionName string

View Source bucket.js, line 154

Never

Collection

# collections() → {CollectionManager}

Gets a collection manager for this bucket

View Source bucket.js, line 185

Never

# defaultCollection() → {Collection}

Gets a reference to the default collection.

View Source bucket.js, line 165

Never

Collection

# defaultScope() → {Scope}

Gets a reference to the default scope.

View Source bucket.js, line 140

Never

Scope

# async ping(optionsopt, callbackopt) → {Promise.<PingResult>}

Ping returns information from pinging the connections for this bucket.

Parameters:
Name Type Attributes Description
options Object <optional>
reportId string <optional>
serviceTypes Array.<ServiceType> <optional>
timeout number <optional>
callback PingCallback <optional>

View Source bucket.js, line 41

Promise.<PingResult>

# scope(scopeName) → {Scope}

Gets a reference to a specific scope.

Parameters:
Name Type Description
scopeName string

View Source bucket.js, line 128

Never

Scope

# viewIndexes() → {ViewIndexManager}

Gets a view index manager for this bucket

View Source bucket.js, line 175

Never

# async viewQuery(designDoc, viewName, optionsopt, callbackopt) → {Promise.<ViewQueryResult>}

Parameters:
Name Type Attributes Description
designDoc string

The design document containing the view to query

viewName string

The name of the view to query

options Object <optional>
scanConsistency ViewScanConsistency <optional>
skip number <optional>
limit number <optional>
order ViewOrdering <optional>
reduce string <optional>
group boolean <optional>
groupLevel number <optional>
key string <optional>
keys Array.<string> <optional>
range Object <optional>
range.start string | Array.<string> <optional>
range.end string | Array.<string> <optional>
range.inclusiveEnd boolean <optional>
idRange Object <optional>
idRange.start string <optional>
idRange.end string <optional>
fullSet boolean <optional>
onError ViewErrorMode <optional>
timeout number <optional>
callback ViewQueryCallback <optional>

View Source bucket.js, line 114

Promise.<ViewQueryResult>