public class ClusterConfig extends Object
ClusterConfig
holds bucket and global configurations in a central place.Constructor and Description |
---|
ClusterConfig()
Creates a new
ClusterConfig . |
Modifier and Type | Method and Description |
---|---|
Set<String> |
allNodeAddresses() |
BucketConfig |
bucketConfig(String bucketName) |
Map<String,BucketConfig> |
bucketConfigs() |
Map<ServiceType,Set<ClusterCapabilities>> |
clusterCapabilities()
Returns the current cluster capabilities.
|
void |
deleteBucketConfig(String bucketName) |
void |
deleteGlobalConfig() |
GlobalConfig |
globalConfig() |
boolean |
hasClusterOrBucketConfig() |
void |
setBucketConfig(BucketConfig config) |
void |
setGlobalConfig(GlobalConfig config) |
String |
toString() |
public ClusterConfig()
ClusterConfig
.public BucketConfig bucketConfig(String bucketName)
@Stability.Internal public void setBucketConfig(BucketConfig config)
@Stability.Internal public void deleteBucketConfig(String bucketName)
public Map<String,BucketConfig> bucketConfigs()
public GlobalConfig globalConfig()
@Stability.Internal public void setGlobalConfig(GlobalConfig config)
@Stability.Internal public void deleteGlobalConfig()
public boolean hasClusterOrBucketConfig()
public Map<ServiceType,Set<ClusterCapabilities>> clusterCapabilities()
Right now this needs at least one bucket open, and it grabs the capabilities from the first bucket config available. If needed, in the future this can be made more intelligent (caching?).
Copyright © 2020 Couchbase, Inc.. All rights reserved.