need help with Cassandra 1.2 Full GCing -- output of jmap histogram

2014-03-09 Thread Oleg Dulin

I am trying to understand why one of my nodes keeps full GC.

I have Xmx set to 8gigs, memtable total size is 2 gigs.

Consider the top entries from jmap -histo:live @ http://pastebin.com/UaatHfpJ

--
Regards,
Oleg Dulin
http://www.olegdulin.com




How to use CompositeRangeBuilder to query multiple components in a column?

2014-03-09 Thread Lu, Boying
Hi, experts,

I need to query all columns of a row in a column family that meet some 
conditions (see below).  The column is composite column and has following 
format:
... where componentN has String type.

What I want to do is to find out all columns that meet following conditions:

1.   component1 == prefix

2.   value1 <= component2 <= value2

3.   value3 <= component3 <= value4


I want to use
  CompositeRangeBuilder.withPrefix(prefix)  // to match component 1
   .greaterThanEquals(value1)
   .lessThenEquals(value2)  // 
to filter out component2
   .nextComponent()
   .greaterThanEquals(value3)
   .lessThenEquals(value4)  // 
to filter out component3

But I can only use greaterThenEquals() and lessThanEquals() once because the 
nextComponent() is not accessible.
Is there any solution to allow me to do such query?

Thanks a lot

Boying



How many Data centers can Cassandra support?

2014-03-09 Thread Lu, Boying
Hi, experts,

Since the Cassandra 2.x supports DB that across multiple DCs,  my question is 
how many DCs can Cassandra support in practice?

Thanks

Boying



Re: How many Data centers can Cassandra support?

2014-03-09 Thread Tupshin Harper
20, easily.  Probably far more, but I lack data points beyond that.

-Tupshin
On Mar 9, 2014 10:26 AM, "Lu, Boying"  wrote:

> Hi, experts,
>
>
>
> Since the Cassandra 2.x supports DB that across multiple DCs,  my question
> is how many DCs can Cassandra support in practice?
>
>
>
> Thanks
>
>
>
> Boying
>
>
>


Re: need help with Cassandra 1.2 Full GCing -- output of jmap histogram

2014-03-09 Thread Takenori Sato
You have millions of org.apache.cassandra.db.DeletedColumn instances on the
snapshot.

This means you have lots of column tombstones, and I guess, which are read
into memory by slice query.


On Sun, Mar 9, 2014 at 10:55 PM, Oleg Dulin  wrote:

> I am trying to understand why one of my nodes keeps full GC.
>
> I have Xmx set to 8gigs, memtable total size is 2 gigs.
>
> Consider the top entries from jmap -histo:live @
> http://pastebin.com/UaatHfpJ
>
> --
> Regards,
> Oleg Dulin
> http://www.olegdulin.com
>
>
>


Cassandra Memory Question

2014-03-09 Thread Gareth Collins
Hello,

I have a question about CQL memory usage. I am currently using 1.2.9.

If I have a Cassandra table like this (created using Astyanax API):

CREATE TABLE table_name (
  key text,
  column1 text,
  value blob,
  PRIMARY KEY (key, column1)
) WITH COMPACT STORAGE;

and I run a query like this:

select key from table_name;

Will Cassandra filter the "key" from the row as it goes...or will it
get all the rows first (i.e. requiring the whole table in memory),
then filter out the "key"? Or will it filter each row as it goes?

I ask because I am researching an OOM on our Cassandra system. I
believe there must be a query "select * from table_name" (each value
blob is very large - I see the value blobs in the Cassandra hprof),
which would explain the OOM. However I am told the query is "select
key from table_name". If it needs to read the whole table into memory
anyway, this would explain the OOM (BTW - I know that this type of
query is usually a bad idea without some type of paging).

As a supplementary question, is there any way to actually trace the
CQL query test? I turned on the tracing described here:

http://www.datastax.com/dev/blog/advanced-request-tracing-in-cassandra-1-2

Whilst I found the bad query (I was able to match it to the thread
name from the OOM Exception), the trace did not appear to be storing
the original query text. The only CQL text I saw in the trace was from
those queries done from cqlsh.

thanks in advance,
Gareth