SessionCreateKeyspaceIfNotExists Method |
Creates new keyspace in current cluster.
If keyspace with specified name already exists, then this method does nothing.
Namespace:
Dse
Assembly:
Dse (in Dse.dll) Version: 2.6.0
Syntax public void CreateKeyspaceIfNotExists(
string keyspaceName,
Dictionary<string, string> replication = null,
bool durableWrites = true
)
Parameters
- keyspaceName
- Type: SystemString
Case-sensitive name of keyspace to be created. - replication (Optional)
- Type: System.Collections.GenericDictionaryString, String
Replication property for this keyspace.
To set it, refer to the ReplicationStrategies class methods.
It is a dictionary of replication property sub-options where key is a sub-option name and value is a value for that sub-option.
Default value is 'SimpleStrategy' with 'replication_factor' = 2
- durableWrites (Optional)
- Type: SystemBoolean
Whether to use the commit log for updates on this keyspace. Default is set to true.
Implements
ISessionCreateKeyspaceIfNotExists(String, DictionaryString, String, Boolean)See Also