incubator-cassandra-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Aaron Morton <aa...@thelastpickle.com>
Subject Re: Range Queries in RP on SCF in 0.7 with UUID SCs
Date Wed, 01 Dec 2010 21:25:01 GMT
The Partitioner applies to the row keys, not the columns. Their order is determined by the
compare_with and compare_subcolumns_with CF settings. 

So where you say "get the last 25 inserts for a key" I'm translating that into "get the most
recent 25 super columns for a row, where the super column names are UUID's and the CF definition
has compare_with:  TimeUUIDType" 

You can send a get_slice where the SliceRange has count=25 and reversed=True. If you know
the 25th col name you can use it as the start param, and AFAIK the operation would go faster.
Not sure how this translates into calls against Pelops. 

This assumes you are using time / v1 UUID's that have an increasing order. 

Hope that helps. 

Aaron


On 02 Dec, 2010,at 09:19 AM, Frank LoVecchio <frank@isidorey.com> wrote:

Is it possible to perform paginated queries using Random Partitioner in 0.7 with Super Column
Families whose Super Columns are UUID's?  I don't believe it is, based on this article: http://ria101.wordpress.com/2010/02/22/cassandra-randompartitioner-vs-orderpreservingpartitioner,
and my attempts with Pelops.

Let's say I get the last 25 inserts for a key.  I now know the 25th Super Column UUID, and
I want to start from there and get the next 25 inserts.  Do I have to change over to Order
Preserving Partitioner?  I'd like to avoid this at all costs.

Thanks,

Frank

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
    • Unnamed multipart/related (inline, None, 0 bytes)
View raw message