Return-Path: Delivered-To: apmail-cassandra-user-archive@www.apache.org Received: (qmail 34026 invoked from network); 12 Sep 2010 23:10:50 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 12 Sep 2010 23:10:50 -0000 Received: (qmail 48991 invoked by uid 500); 12 Sep 2010 23:10:48 -0000 Delivered-To: apmail-cassandra-user-archive@cassandra.apache.org Received: (qmail 48939 invoked by uid 500); 12 Sep 2010 23:10:47 -0000 Mailing-List: contact user-help@cassandra.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@cassandra.apache.org Delivered-To: mailing list user@cassandra.apache.org Received: (qmail 48929 invoked by uid 99); 12 Sep 2010 23:10:47 -0000 Received: from Unknown (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 12 Sep 2010 23:10:47 +0000 X-ASF-Spam-Status: No, hits=2.2 required=10.0 tests=FREEMAIL_FROM,HTML_MESSAGE,RCVD_IN_DNSWL_NONE,SPF_PASS,T_TO_NO_BRKTS_FREEMAIL X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: local policy) Received: from [206.190.58.168] (HELO web55204.mail.re4.yahoo.com) (206.190.58.168) by apache.org (qpsmtpd/0.29) with SMTP; Sun, 12 Sep 2010 23:10:24 +0000 Received: (qmail 40995 invoked by uid 60001); 12 Sep 2010 23:10:03 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s1024; t=1284333001; bh=W/52IoPiJicCoww/W9B7wXN6IJv09445J9sgdTbRtNU=; h=Message-ID:X-YMail-OSG:Received:X-Mailer:References:Date:From:Subject:To:In-Reply-To:MIME-Version:Content-Type; b=forWQ7y+TaaXKW/1IGj+ux3bpOqNnlp29o3XGr+M0tWHh0dsdyE+WqKfYuktfje1qwS3stZ3voT8oSufpc2i6x+W7TQKU4r9y287f1mXHLy+m9k11AUb5QcscfnlxEYVkMnklpy4Y0QlUJ4UtbPoCVa1HYEah8Skc60yMFaiblk= DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; h=Message-ID:X-YMail-OSG:Received:X-Mailer:References:Date:From:Subject:To:In-Reply-To:MIME-Version:Content-Type; b=dSmujHRuIb3MqeIkuxhWN8ZkKE9sc0WxvGc2Tm7f6UONb8vh0NoRPvBo+2iJLYRsEAD1Gd5q2vLZTY6p8Nkdc0AA0rcyy6lStjzDDrADQZCaSKRxK9Rt100/wqhm+bmdiOnl2DwS2HwFGCXUMfhDB3aOFRhNc+DlMKaX2CqcsuU=; Message-ID: <614727.28922.qm@web55204.mail.re4.yahoo.com> X-YMail-OSG: tDfutRAVM1kehqZ9SIxgGLDTF.5625qz76j7wSR8ya34YXW h3l8XgOiSxRK73eS_MfqPUxQciw3HsbaLJhQxmwR6b_ZevHuYOcBEwvCbLSd r2sG6dra2TWIXvhEYEphkRv_Q0VNfsefJbQ_xWvdofrditz8p5c59Fer3c1W R4dsL8RyKPr95sf5NWE6GWPC_ZTapMlTbA0zF_2xp_ARnPKJ8NHwYKpImNN6 zVkhtqyQaqizdFKV1pyWgTrx0U.H1P_fYwt8NC7N6L4E7Y297P_LlsTHWjM0 It2j_G.BhZkHBTY1dYo99ntUN0Cx70ROR5RpkTcK.BhT_P5NqmAmlAT9Gzrc L2r0wQJdPy6shiSmnuD2ZKfz61P27 Received: from [67.161.10.126] by web55204.mail.re4.yahoo.com via HTTP; Sun, 12 Sep 2010 16:10:01 PDT X-Mailer: YahooMailRC/470 YahooMailWebService/0.8.105.279950 References: <249809.22549.qm@web55201.mail.re4.yahoo.com> Date: Sun, 12 Sep 2010 16:10:01 -0700 (PDT) From: kannan chandrasekaran Subject: Re: Couple of cache related questions To: user@cassandra.apache.org In-Reply-To: MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="0-1819829274-1284333001=:28922" X-Virus-Checked: Checked by ClamAV on apache.org --0-1819829274-1284333001=:28922 Content-Type: text/plain; charset=us-ascii Thanks for the replies Jonathan...Couple more clarifications(in bold) ________________________________ From: Jonathan Ellis To: user@cassandra.apache.org Sent: Sun, September 12, 2010 1:47:09 PM Subject: Re: Couple of cache related questions On Sun, Sep 12, 2010 at 2:56 PM, kannan chandrasekaran wrote: > 1) What determines the amount of memory used per schema ignoring the general > overhead to get cassandra up and running? Is it just the size of the caches > for the column Family + the memtable size ? and the bloom filter and index samples from the sstable files. Does that mean that cassandra tries to load the index and filter tables in memory as well, for each sstable in the keyspace? Once the final memtable is flushed to the disk ( assuming no more writes) , does read path also incur the memory size of the memtable for that particular CF ? Does cassandra try to preallocate memory after startup for each schema even if its not used ( not being currently written to or read from) ? I apologize for so many questions,here is what I am trying to do .... I might need more than one schema to be configured and wondering if cassandra will take up memory proportional to the number of schemas "configured" as opposed to the ones "currently in use". This in-turn will help me decide on the maximum number of keyspaces that I can configure within a given heap size. > 2) Is the size of the cache configured ( in terms of absolute numbers or > percentages), an upper bound on the amount of memory that can be allocated > and which grows as more data is filled up in the cache ? no. it's strictly the number of items you give it. so you need to be careful not to make it larger than you have room in the heap. If I understand you correctly then I need to make sure that the sum of sizes of all items in the cache across all the keyspaces + memtable + bloom filter + index samples < Heap space Thanks once again. -- Jonathan Ellis Project Chair, Apache Cassandra co-founder of Riptano, the source for professional Cassandra support http://riptano.com --0-1819829274-1284333001=:28922 Content-Type: text/html; charset=us-ascii
Thanks for the replies Jonathan...Couple more clarifications (in bold)


From: Jonathan Ellis <jbellis@gmail.com>
To: user@cassandra.apache.org
Sent: Sun, September 12, 2010 1:47:09 PM
Subject: Re: Couple of cache related questions

On Sun, Sep 12, 2010 at 2:56 PM, kannan chandrasekaran
<ckannanck@yahoo.com> wrote:
> 1) What determines the amount of memory used per schema ignoring the general
> overhead to get cassandra up and running?  Is it just the size of the caches
> for the column Family + the memtable size ?

and the bloom filter and index samples from the sstable files.

Does that mean that cassandra tries to load the index and filter tables in memory as well, for each sstable in the keyspace?

Once the final memtable is flushed to the disk ( assuming no more writes) , does read path also incur the memory size of the memtable for that particular CF ?

Does cassandra try to preallocate memory after startup for each schema even if its not used ( not being currently written to or read from)  ?

I apologize for so many questions,here is what I am trying to do ....
 I might need more than one schema to be configured and wondering if cassandra will take up memory proportional to the number of schemas "configured" as opposed to the ones "currently in use". This in-turn will help me decide on the maximum number of keyspaces that I can configure within a given heap size.


> 2) Is the size of the cache configured ( in terms of absolute numbers or
> percentages), an upper bound on the amount of memory that can be allocated
> and which grows as more data is filled up in the cache ?

no.  it's strictly the number of items you give it.  so you need to be
careful not to make it larger than you have room in the heap.

If I understand you correctly then I need to make sure that
 the sum of sizes of all items in the cache across all the keyspaces + memtable + bloom filter + index samples  < Heap space

Thanks once again.
--
Jonathan Ellis
Project Chair, Apache Cassandra
co-founder of Riptano, the source for professional Cassandra support
http://riptano.com

--0-1819829274-1284333001=:28922--