So for upgrading Paxos to v2, the non-serial consistency level should be set to 
ANY or LOCAL_QUORUM, and the serial consistency level should still be SERIAL or 
LOCAL_SERIAL. Got it, thanks!

From: Laxmikant Upadhyay <laxmikant....@gmail.com>
Date: Tuesday, 12 March 2024 at 7:33 am
To: user@cassandra.apache.org <user@cassandra.apache.org>
Cc: Weng, Justin <justin.w...@netapp.com>
Subject: Re: Question about commit consistency level for Lightweight 
Transactions in Paxos v2
You don't often get email from laxmikant....@gmail.com. Learn why this is 
important<https://aka.ms/LearnAboutSenderIdentification>

EXTERNAL EMAIL - USE CAUTION when clicking links or attachments


You need to set both in case of lwt. your regular non -serial consistency level 
will only applied during commit phase of lwt.


On Wed, 6 Mar, 2024, 03:30 Weng, Justin via user, 
<user@cassandra.apache.org<mailto:user@cassandra.apache.org>> wrote:
Hi Cassandra Community,

I’ve been investigating Cassandra Paxos v2 (as implemented in 
CEP-14<https://cwiki.apache.org/confluence/display/CASSANDRA/CEP-14%3A+Paxos+Improvements>)
 which improves the performance of lightweight transaction (LWT). But I’ve got 
a question about setting the commit consistency level for LWT after upgrading 
Paxos.

In 
cqlsh<https://docs.datastax.com/en/cql-oss/3.3/cql/cql_reference/cqlshSerialConsistency.html>,
 gocql<https://github.com/gocql/gocql/blob/master/session.go#L1247> and Python 
driver<https://docs.datastax.com/en/developer/python-driver/3.29/api/cassandra/query/#cassandra.query.Statement.serial_consistency_level>,
 there are two settings for consistency levels: normal Consistency Level and 
Serial Consistency Level. As mentioned in the cqlsh 
documentation<https://docs.datastax.com/en/cql-oss/3.3/cql/cql_reference/cqlshSerialConsistency.html>,
 Serial Consistency Level is only used for LWT and can only be set to either 
SERIAL or LOCAL_SERIAL. However, the Steps for Upgrading 
Paxos<https://github.com/apache/cassandra/blob/trunk/NEWS.txt#L532> and 
CEP-14<https://cwiki.apache.org/confluence/display/CASSANDRA/CEP-14%3A+Paxos+Improvements>
 mention that ANY or LOCAL_QUOROM can be used as the commit consistency level 
for LWT after upgrading Paxos to v2. Therefore, I have a question about how to 
correctly set the commit consistency level to ANY or LOCAL_QUORUM for LWT. 
Namely, which consistency level should I set, the normal Consistency Level or 
Serial Consistency Level?

Any help would be really appreciated.

Thanks,
Justin

Reply via email to