I think this is reasonable assuming you have enough backhaul to perform
reads across DC if read requests hit DC2 (with one copy of data) or one
replica from DC1 is down.

Moreover, since you clearly stated that you would prefer availability over
consistency, you should be prepared for stale reads :)


On Tue, Apr 12, 2011 at 8:12 AM, Raj N <raj.cassan...@gmail.com> wrote:

> Hi experts,
>      We are planning to deploy Cassandra in 2 datacenters. Let assume there
> are 3 nodes, RF=3, 2 nodes in 1 DC and 1 node in 2nd DC. Under normal
> operations, we would read and write at QUORUM. What we want to do though is
> if we lose a datacenter which has 2 nodes, DC1 in this case, we want to
> downgrade our consistency to ONE. Basically I am saying that whenever there
> is a partition, then prefer availability over consistency. In order to do
> this we plan to catch UnavailableException and take corrective action. So
> try QUORUM under normal circumstances, if unavailable try ONE. My questions
> -
> Do you guys see any flaws with this approach?
> What happens when DC1 comes back up and we start reading/writing at QUORUM
> again? Will we read stale data in this case?
>
> Thanks
> -Raj
>



-- 
Narendra Sharma
Solution Architect
*http://www.persistentsys.com*
*http://narendrasharma.blogspot.com/*

Reply via email to