cassandra - Query all and consistency -


this question regarding behavior of cassandra select * query. it's more understanding, know normaly should not execute such query.

assuming have 4 nodes rf=2. following table (column family): create table test_storage ( id text, created_on timestamp, location int, data text, primary key(id) ); inserted 100 entries table.

now select * test_storage via cqlsh. doing query multiple times different results, not entries. when changing consistency local_quorum complete result. why so? assumed, despite performance, consistency 1 entries since must query whole token range.

second issue, when add secondary index in case location, , query select * test_storage location=1 random results wiht consistency one. , correct results when changing consistency level local_quorum. here don't understand why happens?

when changing consistency local_quorum complete result. why so?

welcome eventual consistency world. understand it, read slides: http://www.slideshare.net/doanduyhai/cassandra-introduction-2016-60292046/31

i assumed, despite performance, consistency 1 entries since must query whole token range

yes, cassandra query token ranges because of non restricted select * request data 1 replicas out of 2 (rf=2)

and query select * test_storage location=1 random results wiht consistency one

same answer above, native cassandra secondary index using cassandra table under hood store reverse-index same eventual consistency rules apply there too


Comments

Popular posts from this blog

javascript - Laravel datatable invalid JSON response -

java - Exception in thread "main" org.springframework.context.ApplicationContextException: Unable to start embedded container; -

sql server 2008 - My Sql Code Get An Error Of Msg 245, Level 16, State 1, Line 1 Conversion failed when converting the varchar value '8:45 AM' to data type int -