Was this page helpful?
Application Best Practices for ScyllaDB Cloud¶
These recommendations apply to the applications and keyspace schemas you build on top of ScyllaDB Cloud. Following them ensures high availability, consistent performance, and efficient use of your cluster.
Use NetworkTopology Replication Strategy¶
NetworkTopologyStrategy is the only replication strategy suitable for
production use. It is also the default in ScyllaDB — you do not need to
specify it explicitly when creating a keyspace.
All of the following are valid and equivalent:
-- Omit replication entirely (defaults to NetworkTopologyStrategy)
CREATE KEYSPACE my_keyspace;
-- Specify the class explicitly
CREATE KEYSPACE my_keyspace WITH replication = {
'class': 'NetworkTopologyStrategy',
'replication_factor': 3
};
-- Specify per-DC replication
CREATE KEYSPACE my_keyspace WITH replication = {
'class': 'NetworkTopologyStrategy',
'<datacenter_name>': 3
};
If you do specify a replication strategy, always use NetworkTopologyStrategy.
Never use SimpleStrategy in a production environment — it does not account
for Availability Zone placement, does not support Multi-DC configurations, and
cannot be changed later on tablet-based keyspaces.
Learn more: CREATE KEYSPACE — ScyllaDB Docs
Use the Correct Consistency Level¶
For a single-DC cluster, use Quorum consistency.
For a Multi-DC cluster, use LocalQuorum consistency.
Using ONE or ANY reduces durability. Using ALL reduces
availability — if any replica is down, the query will fail.
Match the Replication Factor to Your Cluster¶
When creating keyspaces, set the Replication Factor (RF) to match the RF you selected when creating the cluster. A lower RF reduces availability; a higher RF may place more than one replica in the same Availability Zone, which is wasteful and provides no additional fault tolerance.