update Bucket
suspend fun updateBucket(name: String, common: CommonOptions = CommonOptions.Default, ramQuota: StorageSize? = null, flushEnabled: Boolean? = null, replicas: Int? = null, maximumExpiry: Expiry? = null, compressionMode: CompressionMode? = null, minimumDurability: Durability? = null, evictionPolicy: EvictionPolicyType? = null, @SinceCouchbase(value = "7.2" ) historyRetentionCollectionDefault: Boolean? = null, @SinceCouchbase(value = "7.2" ) historyRetentionSize: StorageSize? = null, @SinceCouchbase(value = "7.2" ) historyRetentionDuration: Duration? = null)
Content copied to clipboard
Modifies an existing bucket.
Samples
import com.couchbase.client.kotlin.Cluster
import com.couchbase.client.kotlin.util.StorageSize.Companion.mebibytes
fun main() {
//sampleStart
// Modify the RAM quota of an existing bucket
cluster.buckets.updateBucket(
name = "my-bucket",
ramQuota = 1024.mebibytes,
)
//sampleEnd
}
Throws
com. couchbase. client. core. error. Bucket Not Found Exception
if the bucket does not exist
Content copied to clipboard