Many drivers have a downgrading consistency feature that does it for you, but really you probably want to catch the timeout or unavailable exception and handle it in your app
-- Jeff Jirsa > On Apr 19, 2018, at 5:52 AM, Venkata Hari Krishna Nukala > <n.v.harikrishna.apa...@gmail.com> wrote: > > Hi, > > I am working on a C* cluster which is installed on two data centres. Our app > is in installed on those data centres and they serve life traffic all the > time. Keyspaces are configure with NetworkTopologyStrategy and we are using > LOCAL_QUORUM. Now I have got a case where stronger consistency is required > across DCs, so would like to switch to EACH_QUORUM. > > Suppose if one DC goes down, I would like to fallback to LOCAL_QUORUM so that > our app can continue serving requests and data can be eventually consistent > when it is up. > > Now the question is: how to detect if a DC is down programmatically at the > client so that I can switch the consistency level? > > Thanks! --------------------------------------------------------------------- To unsubscribe, e-mail: user-unsubscr...@cassandra.apache.org For additional commands, e-mail: user-h...@cassandra.apache.org