From user-return-64358-archive-asf-public=cust-asf.ponee.io@cassandra.apache.org Sun Aug 18 00:55:44 2019 Return-Path: X-Original-To: archive-asf-public@cust-asf.ponee.io Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [207.244.88.153]) by mx-eu-01.ponee.io (Postfix) with SMTP id 0EB38180181 for ; Sun, 18 Aug 2019 02:55:43 +0200 (CEST) Received: (qmail 60247 invoked by uid 500); 18 Aug 2019 00:55:41 -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 60237 invoked by uid 99); 18 Aug 2019 00:55:41 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd2-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 18 Aug 2019 00:55:41 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd2-us-west.apache.org (ASF Mail Server at spamd2-us-west.apache.org) with ESMTP id AA8C21A3444 for ; Sun, 18 Aug 2019 00:55:40 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd2-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 1.8 X-Spam-Level: * X-Spam-Status: No, score=1.8 tagged_above=-999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, HTML_MESSAGE=2, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001] autolearn=disabled Authentication-Results: spamd2-us-west.apache.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com Received: from mx1-he-de.apache.org ([10.40.0.8]) by localhost (spamd2-us-west.apache.org [10.40.0.9]) (amavisd-new, port 10024) with ESMTP id aI40dnDwbdju for ; Sun, 18 Aug 2019 00:55:38 +0000 (UTC) Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=2607:f8b0:4864:20::d30; helo=mail-io1-xd30.google.com; envelope-from=devopam@gmail.com; receiver= Received: from mail-io1-xd30.google.com (mail-io1-xd30.google.com [IPv6:2607:f8b0:4864:20::d30]) by mx1-he-de.apache.org (ASF Mail Server at mx1-he-de.apache.org) with ESMTPS id BDB6C7D3FA for ; Sun, 18 Aug 2019 00:55:37 +0000 (UTC) Received: by mail-io1-xd30.google.com with SMTP id l7so13734985ioj.6 for ; Sat, 17 Aug 2019 17:55:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to; bh=qVI8p4xRUnsbaPa1pJyDQUcOkANkwr+h0Hysd4yyeqM=; b=GFg763qJC5D4KBDPXxAbJwNyWM7xw47hGRb1BGl2sI+pFVCXm5t3njt6dV84eRRQel bVOBdVvEm1w3QUWKuGRQx54oh9n+0ONcgDmU1FHi4PkPTMDNyoL+ZN4HkLyOXOY7ZzcL tHhHdsGqB4ADpn9PRHNDJaQVfS4xBMwag9poNKnEwx3U4eVgJik/EWjJzkbH/XG7DSLC Qrq35f6ZjrRxiYh3qZrYLXK0E0dZUivDbR02tYxO/CejLn76QKnGLvFHv/TVYs9Q26pS 48Xf3Mkarh2x35ylVwLhie8zy44R/q1p02NBZ8fYtMeHr2xRIwSvcPqCJf/3p7iG9Blv FxgA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to; bh=qVI8p4xRUnsbaPa1pJyDQUcOkANkwr+h0Hysd4yyeqM=; b=gpzxbeg6KvhB63H65t0FIawJY9RK1oRias5xNnxnPxp1zz0SRyTWpja/a9Lk+HFw5b 2fNkAqzJcu+vfmJUJAEraLw2o4xU1FOCeTkgJ0LAf1/Sf0LjcE/rWW0K7ZLmiZUv+Ovd 2Ywm2UCeoOY6H9y+KeANeKCjUt2foPC/rMKOCBKAd6etSXlTBWmW98br8ElUf6aJaVLL /taBMU70WB7S7Dm5uSn68pm3PE2VgAIOL9hYjHZ8/YTHBSFppRd/9CIwdnEFswXijWaN 5/qTEROXGPn+v9acd5Lv1YfWtzquIl8OUQEJD6BtnQz8IERFaH6NCiT0oF0KJxQTmN4P 6OZQ== X-Gm-Message-State: APjAAAWfH6+82X8Kh7y4JsmLajGs6u+JROpd1PuR12L/z2d0/JHLl08h Ysy6v9z2iUE5CGPuaOE6KrPa+mqG8kEIko103EOxQg== X-Google-Smtp-Source: APXvYqzN1jxCgowQkYbzqypVlviE/wsi6pcwpsvPD1itxbFY5ahpX5NhNEi5jyFmuVpgYuSWZEAJUHOxD5V9F6ZknbI= X-Received: by 2002:a02:7f54:: with SMTP id r81mr9664087jac.129.1566089736095; Sat, 17 Aug 2019 17:55:36 -0700 (PDT) MIME-Version: 1.0 References: <053247A8CBB6754B8345743B8F18D68D525C62C6@MOSTLS1MSGUSRFA.ITServices.sbc.com> In-Reply-To: <053247A8CBB6754B8345743B8F18D68D525C62C6@MOSTLS1MSGUSRFA.ITServices.sbc.com> From: Devopam Mittra Date: Sun, 18 Aug 2019 06:25:23 +0530 Message-ID: Subject: Re: Performance impact with ALLOW FILTERING clause. To: user@cassandra.apache.org Content-Type: multipart/alternative; boundary="000000000000680d3b059059aef0" --000000000000680d3b059059aef0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Hi Asad, Seems to me that your development team will need to remodel the tables sooner than later. This problem can't be left unattended for long once it starts hitting severely. The way Cassandra is, you may want to have them replicate the same table with different PK / structure to suitably embed a WHERE clause in the base query if nothing else works out. Allow filtering is best avoided for routine queries or at max good for ad-hoc analysis not involving arithmetic operation (like count/sum) . Regards Devopam On Thu, Jul 25, 2019, 7:19 PM ZAIDI, ASAD A wrote: > Hello Folks, > > > > I was going thru documentation and saw at many places saying ALLOW > FILTERING causes performance unpredictability. Our developers says ALLOW > FILTERING clause is implicitly added on bunch of queries by spark-Cassand= ra > connector and they cannot control it; however at the same time we see > unpredictability in application performance =E2=80=93 just as documentati= on says. > > > > I=E2=80=99m trying to understand why would a connector add a clause in qu= ery when > this can cause negative impact on database/application performance. Is th= at > data model that is driving connector make its decision and add allow > filtering to query automatically or if there are other reason this clause > is added to the code. I=E2=80=99m not a developer though I want to know w= hy > developer don=E2=80=99t have any control on this to happen. > > > > I=E2=80=99ll appreciate your guidance here. > > > > Thanks > > Asad > > > > > --000000000000680d3b059059aef0 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Hi Asad,
Seems to me that your deve= lopment team will need to remodel the tables sooner=C2=A0than later. This p= roblem can't be left unattended for long once it starts hitting severel= y.=C2=A0
The way Cassandra is, you may want to have = them replicate the same table with different PK / structure to suitably emb= ed a WHERE clause in the base query if nothing else works out.

Allow filtering is best avoided for = routine queries or at max good for ad-hoc analysis not involving arithmetic= operation (like count/sum) .=C2=A0

Regards
Devopam


On Thu, Jul 25, 2019= , 7:19 PM ZAIDI, ASAD A <az192g@att.co= m> wrote:

Hello Folks,

=C2=A0

I was going thru documentation and sa= w at many places saying ALLOW FILTERING causes performance unpredictability= .=C2=A0 Our developers says ALLOW FILTERING clause is implicitly added on bunch of queries by spark-Cassandra =C2=A0connector= and they cannot control it; however at the same time we see unpredictabili= ty in application performance =E2=80=93 just as documentation says. =C2=A0<= u>

=C2=A0

I=E2=80=99m trying to understand why = would a connector add a clause in query when this can cause negative impact= on database/application performance. Is that data model that is driving connector make its decision and add allow filtering to que= ry automatically or if there are other reason this clause is added to the c= ode. I=E2=80=99m not a developer though I want to know why developer don=E2= =80=99t have any control on this to happen.

=C2=A0

I=E2=80=99ll appreciate your guidance= here.

=C2=A0

Thanks

Asad

=C2=A0

=C2=A0

--000000000000680d3b059059aef0--