Topology awareness through snitches

Snitches map the IP addresses of nodes to physical and virtual locations, such as racks and datacenters. Snitches use gossip to inform the database about the network topology for efficient request routing and replica distribution in datacenters and racks (logical groups). HCD prioritizes placing replicas on different racks whenever possible. Racks can be logical groupings or physical locations depending on your infrastructure.

HCD supports several types of snitches for different deployment environments and network topologies. All nodes in a cluster must use the same snitch. You can switch snitches after deployment, but this might require additional changes or downtime to redistribute the replicas.

Snitch types

HcdSimpleSnitch (default)

Use this snitch only for non-production single-datacenter deployments or single-zone deployments in public clouds. This snitch does not recognize datacenter or rack information. When using this snitch, keyspace definitions must use the SimpleStrategy class and specify a replication factor (1 in single-datacenter deployments).

GossipingPropertyFileSnitch

This snitch is recommended for production. It is the most flexible solution for on-premise or mixed cloud environments. It uses rack and datacenter information for the local node defined in the cassandra-rackdc.properties file and propagates this information to other nodes through gossip.

PropertyFileSnitch

This snitch determines proximity based on the rack and datacenter. It uses the network details located in the cassandra-topology.properties file, which must include every node in the cluster. All nodes must have a copy of the same cassandra-topology.properties file.

When using this snitch, use a standardized naming convention for your datacenters. Keyspace definitions must use the exact datacenter names in the replication map.

RackInferringSnitch

This snitch determines the proximity of nodes by datacenter and rack, which are assumed to correspond to the second and third octet of the node’s IP address, respectively. For example, in the IP address 110.100.200.105, 100 is the datacenter octet, 200 is the rack octet, and 105 is the node (host) octet.

It is best used as an example for writing a custom snitch class, unless this format happens to match your deployment conventions.

Cloud provider snitches

Use these snitches for deployments in specific cloud environments:

Dynamic snitching

By default, all snitches use a dynamic snitch layer that monitors read latency and, when possible, routes requests away from poorly-performing nodes. The dynamic snitch is enabled by default and is recommended for use in most deployments. You can set dynamic snitch thresholds in each node’s cassandra.yaml file. You can also configure the properties for gossip failure detection and recovery.

Was this helpful?

Give Feedback

How can we improve the documentation?

© Copyright IBM Corporation 2026 | Privacy policy | Terms of use |  Manage Privacy Choices

Apache, Apache Cassandra, Cassandra, Apache Tomcat, Tomcat, Apache Lucene, Apache Solr, Apache Hadoop, Hadoop, Apache Pulsar, Pulsar, Apache Spark, Spark, Apache TinkerPop, TinkerPop, Apache Kafka and Kafka are either registered trademarks or trademarks of the Apache Software Foundation or its subsidiaries in Canada, the United States and/or other countries. Kubernetes is the registered trademark of the Linux Foundation.

General Inquiries: Contact IBM