Skip to main content

This content has been archived and is no longer being updated.

Links may not function; however, this content may be relevant to outdated versions of the product.

Configuring the consistency level

Suggest edit Updated on April 5, 2022

This content applies only to On-premises and Client-managed cloud environments

Achieve the level of consistency that you want by deciding how many Cassandra nodes in a cluster must validate a write operation or respond to a read operation to declare success.

Cassandra replicates data across a cluster, and consistency refers to how up-to-date the data is on all replicas within a cluster. A high consistency level requires more nodes to respond to updates to ensure that each replica is the same. The cost of high consistency is an increased time that is needed for all the replicas to update and declare success.

  • To change the consistency level, modify the following prconfig.xml properties:
    • dnode/default_read_consistency

      The default consistency setting for read operations is ONE. The available consistency levels include ONE, TWO, and THREE, each of which specify the total number of replica nodes that must respond to a request. The QUORUM consistency level requires a response from a majority of the replica nodes.

      For example, if read consistency is ONE, Cassandra queries any one of the copies of the data and returns the data from that copy. For multiple nodes, if read consistency is QUORUM, Cassandra queries the majority of the replicas. Cassandra considers the replica with the latest time stamp as the true one and all the other copies are updated with the latest copy.

    • dnode/default_write_consistency

      The default consistency setting for write operations is ONE.

      For example, if write consistency is ONE, Cassandra acknowledges the operation when any replica updates an entry. For multiple nodes, if write consistency is QUORUM, Cassandra acknowledges an operation after the majority of the replicas update entries.

    Note: Adding nodes to a Cassandra cluster does not affect the consistency level.
Did you find this content helpful? YesNo

Have a question? Get answers now.

Visit the Support Center to ask questions, engage in discussions, share ideas, and help others.

We'd prefer it if you saw us at our best.

Pega.com is not optimized for Internet Explorer. For the optimal experience, please use:

Close Deprecation Notice
Contact us