Return-Path: X-Original-To: apmail-cassandra-user-archive@www.apache.org Delivered-To: apmail-cassandra-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 1E5EED272 for ; Mon, 1 Oct 2012 00:43:00 +0000 (UTC) Received: (qmail 35116 invoked by uid 500); 1 Oct 2012 00:42:57 -0000 Delivered-To: apmail-cassandra-user-archive@cassandra.apache.org Received: (qmail 35082 invoked by uid 500); 1 Oct 2012 00:42:57 -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 35073 invoked by uid 99); 1 Oct 2012 00:42:57 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 01 Oct 2012 00:42:57 +0000 X-ASF-Spam-Status: No, hits=1.7 required=5.0 tests=FREEMAIL_ENVFROM_END_DIGIT,HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of owenzhang1990@gmail.com designates 74.125.83.44 as permitted sender) Received: from [74.125.83.44] (HELO mail-ee0-f44.google.com) (74.125.83.44) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 01 Oct 2012 00:42:51 +0000 Received: by eekd4 with SMTP id d4so2247737eek.31 for ; Sun, 30 Sep 2012 17:42:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=snyu/EilObeennGmHifA1uni8fSvtUEiWqRZBaNZ3/4=; b=RfU5FksMFaWOUz7fPk4U2H/um2cHzGfMb7A18MHiY3uqXT8GMpSUbE0FzKqlKC/joJ FrjqENLRHG0oHz3VFeskz5QV8zyyFsOnfLo/8SLcVdXKcqngfPOELSaut/CE6AfbWWqx 1frLnfp6qvBPuNy72L65ewHtjLBPW7a0yEGNMMmO+sTGMPxBWhm9wUuEDueKEcdnyKCM Fw+wXThU29/+8heQ8udhfn/z/SB02mWrH6Pcx+Wm63S+psdIMii+l3LQz2j8xRsXyUGf /G+wUdSAwW0IWCcG2hSw/9bp4zuxy2gE2b/2UITba9zZBH9dsh6HfSaKE7HTsPVZGD0J 6b7w== MIME-Version: 1.0 Received: by 10.14.215.193 with SMTP id e41mr16267141eep.44.1349052151201; Sun, 30 Sep 2012 17:42:31 -0700 (PDT) Received: by 10.14.209.198 with HTTP; Sun, 30 Sep 2012 17:42:31 -0700 (PDT) In-Reply-To: <486AC2B5-3825-4D16-8F6C-D4B3F54E7DDF@thelastpickle.com> References: <486AC2B5-3825-4D16-8F6C-D4B3F54E7DDF@thelastpickle.com> Date: Mon, 1 Oct 2012 08:42:31 +0800 Message-ID: Subject: Re: From: Manu Zhang To: user@cassandra.apache.org Content-Type: multipart/alternative; boundary=e89a8f647ac341808e04caf4aee7 --e89a8f647ac341808e04caf4aee7 Content-Type: text/plain; charset=ISO-8859-1 Sorry, the line "I still don't see it in jconsole" is ambiguous. I mean that I don't find a change of rowcache size in jconsole and neither performance gain. cfstats gives either 0 or NaN. On Mon, Oct 1, 2012 at 8:17 AM, aaron morton wrote: > I still don't see it in jconsole. > > It's part of the CF definition. > > Check the docs for CLI or CQL which ever you are using. > > how long would you expect to cost to read a column family of 150000 rows > if it fits into row cache entirely? It takes me around 7s now > > Assuming you are talking about the client side timing for reading 150,000 > rows with several columns each this does not sound too crazy. > > Check the server side timing by calling nodetool cfstats before and after > the query, the recent stats will be be since the last time cfstats was > called. > > Cheers > > ----------------- > Aaron Morton > Freelance Developer > @aaronmorton > http://www.thelastpickle.com > > On 27/09/2012, at 2:32 PM, Manu Zhang wrote: > > I still don't see it in jconsole. BTW, how long would you expect to cost > to read a column family of 150000 rows if it fits into row cache entirely? > It takes me around 7s now. My experiment is done on a single node. > > On Thu, Sep 27, 2012 at 6:00 AM, aaron morton wrote: > >> Set the caching strategy for the CF to be ROWS_ONLY. >> >> Cheers >> >> ----------------- >> Aaron Morton >> Freelance Developer >> @aaronmorton >> http://www.thelastpickle.com >> >> On 26/09/2012, at 2:18 PM, Manu Zhang wrote: >> >> The DEFAULT_CACHING_STRATEGY is Caching.KEYS_ONLY but even configuring >> row cache size to be greater zero >> won't enable row cache. Why? >> >> On Wed, Sep 26, 2012 at 9:44 AM, Manu Zhang wrote: >> >>> I wonder now if "get_range_slices" call will ever look for data in row >>> cache. I don't see it in the codebase. Only the "get" call will check row >>> cache? >>> >>> >>> On Wed, Sep 26, 2012 at 12:11 AM, Charles Brophy wrote: >>> >>>> There are settings in cassandra.yaml that will _gradually_ reduce the >>>> available cache to zero if you are under constant memory pressure: >>>> >>>> # Set to 1.0 to disable. >>>> reduce_cache_sizes_at: * >>>> reduce_cache_capacity_to: * >>>> >>>> My experience is that the cache size will not return to the configured >>>> size until a service restart if you leave this enabled. The text of this >>>> setting is not explicit about the long-term cache shrinkage, so it's easy >>>> to think that it will restore the cache to its configured size after the >>>> pressures have subsided. It won't. >>>> >>>> Charles >>>> >>>> On Tue, Sep 25, 2012 at 8:14 AM, Manu Zhang wrote: >>>> >>>>> I've enabled row cache and set its capacity to 10MB but when I check >>>>> its size in jconsole it's always 0. Isn't it that a row will be written to >>>>> row cache if it isn't there when I read the row? I've bulk loaded the data >>>>> into disk so row cache is crucial to the performance. >>>> >>>> >>>> >>> >> >> > > --e89a8f647ac341808e04caf4aee7 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Sorry, the line "I still don't see it in jconsole" is ambiguo= us. I mean that I don't find a change of rowcache size in jconsole and = neither performance gain. cfstats gives either 0 or NaN.

On Mon, Oct 1, 2012 at 8:17 AM, aaron morton <aaron@thelastpickle.c= om> wrote:
I still don't see it in jconsole.
It's part = of the CF definition.=A0

Check the docs for CLI or CQL w= hich ever you are using.=A0

how long wo= uld you expect to cost to read a column family of 150000 rows if it fits in= to row cache entirely? It takes me around 7s now
Assuming= you are talking about the client side timing for reading 150,000 rows with= several columns each this does not sound too crazy.=A0

Check the server side timing by calling nodetool cfstat= s before and after the query, the recent stats will be be since the last ti= me cfstats was called.=A0

Cheers

<= div style=3D"word-wrap:break-word">
-----------------
Aaron Morton
Freelance Deve= loper
@aaronmorton

On 27/09/2012, at 2:32 PM, Manu = Zhang <owen= zhang1990@gmail.com> wrote:

I sti= ll don't see it in jconsole. BTW, how long would you expect to cost to = read a column family of 150000 rows if it fits into row cache entirely? It = takes me around 7s now. My experiment is done on a single node.

On Thu, Sep 27, 2012 at 6:00 AM, aaron morto= n <aaron@thelastpickle.com> wrote:
Set the caching strategy for the CF to = be ROWS_ONLY.

Cheers

-----------------
Aaron Morton
Freelance Deve= loper
@aaronmorton

On 26/09/2012, at 2:18 PM, Manu Zhang <owenzhang1990@gmail.com> w= rote:

The DEFAULT_CACHING_STRATEGY is Ca= ching.KEYS_ONLY but even configuring row cache size to be greater zero=A0 =A0won't enable row cache. Why?=A0

O= n Wed, Sep 26, 2012 at 9:44 AM, Manu Zhang <owenzhang1990@gmail.com<= /a>> wrote:
I wonder now if "get_range_slices"= call will ever look for data in row cache. I don't see it in the codeb= ase. Only the "get" call will check row cache?


On Wed, Sep 26, 2012 at 12:11 AM, C= harles Brophy <cbrophy@zulily.com> wrote:
There are settings in cassandra.yaml that wi= ll _gradually_ reduce the available cache to zero if you are under constant= memory pressure:

=A0# Set to 1.0 to disable. =A0<snip>
r= educe_cache_sizes_at: *
reduce_cache_capacity_to: *

My experience is that = the cache size will not return to the configured size until a service resta= rt if you leave this enabled. =A0The text of this setting is not explicit a= bout the long-term cache shrinkage, so it's easy to think that it will = restore the cache to its configured size after the pressures have subsided.= It won't.=A0

Charles

On Tue, Sep 25, 2012 at 8:14 AM, Manu Zhang = <owenzhang1= 990@gmail.com> wrote:
I've enabled row cache and set its capac= ity to 10MB but when I check its size in jconsole it's always 0. Isn= 9;t it that a row will be written to row cache if it isn't there when I= read the row? I've bulk loaded the data into disk so row cache is cruc= ial to the performance.






--e89a8f647ac341808e04caf4aee7--