MCPcopy Index your code
hub / github.com/couchbase/couchbase-python-client / bucket

Method bucket

couchbase/cluster.py:116–134  ·  view source on GitHub ↗

Creates a Bucket instance to a specific bucket. .. seealso:: :class:`.bucket.Bucket` Args: bucket_name (str): Name of the bucket to reference Returns: :class:`~couchbase.bucket.Bucket`: A bucket instance Raises: Runt

(self, bucket_name: str)

Source from the content-addressed store, hash-verified

114 self._impl.close_connection()
115
116 def bucket(self, bucket_name: str) -> Bucket:
117 """Creates a Bucket instance to a specific bucket.
118
119 .. seealso::
120 :class:`.bucket.Bucket`
121
122 Args:
123 bucket_name (str): Name of the bucket to reference
124
125 Returns:
126 :class:`~couchbase.bucket.Bucket`: A bucket instance
127
128 Raises:
129 RuntimeError: If called prior to the cluster being connected.
130 :class:`~couchbase.exceptions.BucketNotFoundException`: If provided `bucket_name` cannot
131 be found.
132
133 """
134 return Bucket(self, bucket_name)
135
136 def cluster_info(self) -> ClusterInfoResult:
137 """Retrieve the Couchbase cluster information

Callers 15

test_kv_op_chainMethod · 0.95
mainFunction · 0.95
runFunction · 0.95
mainFunction · 0.95
mainFunction · 0.95
mainFunction · 0.95
mainFunction · 0.95
mainFunction · 0.95
mainFunction · 0.95
mainFunction · 0.95

Calls 1

BucketClass · 0.90

Tested by 3

test_kv_op_chainMethod · 0.76