skip to main content
Connection Property Descriptions : WriteConsistency
  

Try DataDirect Drivers Now

WriteConsistency

Purpose

Determines the number of replicas on which the write must succeed before returning an acknowledgment to the client application.

Valid Values

all | quorum | one | all | each_quorum | quorum | local_quorum | one | two | three | local_one | any | serial | local_serial

Behavior

If set to all, a write must succeed on all replica nodes in the cluster for that partition key. This setting provides the highest consistency and lowest availability.
If set to each_quorum, a write must succeed on a quorum of replica nodes across a data center.
If set to quorum, a write must succeed on a quorum of replica nodes.
If set to local_quorum, a write must succeed on a quorum of replica nodes in the same data center as the coordinator node. This setting voids latency of inter-data center communication.
If set to one, a write must succeed on at least one replica node.
If set to two, a write must succeed on at least two replica nodes.
If set to three, a write must succeed on at least three replica nodes.
If set to local_one, a write must succeed on at least one replica node in the local data center.
If set to any, a write must succeed on at least one node. Even if all replica nodes for the given partition key are down, the write can succeed after a hinted handoff has been written. This setting provides the lowest consistency and highest availability.
If set to serial, the driver prevents unconditional updates to achieve linearizable consistency for lightweight transactions.
If set to local_serial, the driver prevents unconditional updates to achieve linearizable consistency for lightweight transactions within the data center.

Notes

*An update operation can result in a consistency level error if the server does not support the WriteConsistency value specified.
*Refer to Apache Cassandra documentation for more information about configuring consistency levels, including usage scenarios.
*If you wish to specify a ReadConsistency value besides the values documented in this section, contact Technical Support.

Data Source Method

setWriteConsistency

Default

quorum

Data Type

String

See also

*Additional Properties
*Performance Considerations
*ReadConsistency
*ReadOnly