public class Configuration extends Object
| Modifier and Type | Class and Description | 
|---|---|
| static class  | Configuration.BuilderA builder to create a new  Configurationobject. | 
| Modifier | Constructor and Description | 
|---|---|
| protected  | Configuration(Configuration toCopy)Copy constructor. | 
| Modifier and Type | Method and Description | 
|---|---|
| static Configuration.Builder | builder()Returns a builder to create a new  Configurationobject. | 
| CodecRegistry | getCodecRegistry()Returns the  CodecRegistryinstance for this configuration. | 
| String | getDefaultKeyspace() | 
| MetricsOptions | getMetricsOptions()Returns the metrics configuration, if metrics are enabled. | 
| NettyOptions | getNettyOptions()Returns the  NettyOptionsinstance for this configuration. | 
| Policies | getPolicies()Returns the policies set for the cluster. | 
| PoolingOptions | getPoolingOptions()Returns the connection pooling configuration. | 
| ProtocolOptions | getProtocolOptions()Returns the Cassandra binary protocol level configuration (compression). | 
| QueryOptions | getQueryOptions()Returns the queries configuration. | 
| SocketOptions | getSocketOptions()Returns the low-level TCP configuration options used (tcpNoDelay, keepAlive, ...). | 
| ThreadingOptions | getThreadingOptions() | 
protected Configuration(Configuration toCopy)
toCopy - the object to copy from.public static Configuration.Builder builder()
Configuration object.
 You only need this if you are building the configuration yourself. If you use Cluster.builder(), it will be done under the hood for you.
public Policies getPolicies()
public SocketOptions getSocketOptions()
public ProtocolOptions getProtocolOptions()
public PoolingOptions getPoolingOptions()
public MetricsOptions getMetricsOptions()
Metrics collection is enabled by default but can be disabled at cluster construction time
 through Cluster.Builder.withoutMetrics().
null if metrics are not enabled.public QueryOptions getQueryOptions()
public ThreadingOptions getThreadingOptions()
public NettyOptions getNettyOptions()
NettyOptions instance for this configuration.NettyOptions instance for this configuration.public String getDefaultKeyspace()
public CodecRegistry getCodecRegistry()
CodecRegistry instance for this configuration.
 Note that this method could return CodecRegistry.DEFAULT_INSTANCE if no specific
 codec registry has been set on the Cluster. In this case, care should be taken when
 registering new codecs as they would be immediately available to other Cluster
 instances sharing the same default instance.
CodecRegistry instance for this configuration.Copyright © 2012–2025. All rights reserved.