Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 1C25A200C5A for ; Tue, 18 Apr 2017 10:05:01 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id 1AD47160BA1; Tue, 18 Apr 2017 08:05:01 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 3B242160B90 for ; Tue, 18 Apr 2017 10:05:00 +0200 (CEST) Received: (qmail 14720 invoked by uid 500); 18 Apr 2017 08:04:59 -0000 Mailing-List: contact dev-help@ignite.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@ignite.apache.org Delivered-To: mailing list dev@ignite.apache.org Received: (qmail 14706 invoked by uid 99); 18 Apr 2017 08:04:59 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd1-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 18 Apr 2017 08:04:59 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd1-us-west.apache.org (ASF Mail Server at spamd1-us-west.apache.org) with ESMTP id B718DC8794 for ; Tue, 18 Apr 2017 08:04:58 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd1-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 0.416 X-Spam-Level: X-Spam-Status: No, score=0.416 tagged_above=-999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, HTML_MESSAGE=2, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-2.796, SPF_PASS=-0.001, URI_HEX=1.313] autolearn=disabled Authentication-Results: spamd1-us-west.apache.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com Received: from mx1-lw-us.apache.org ([10.40.0.8]) by localhost (spamd1-us-west.apache.org [10.40.0.7]) (amavisd-new, port 10024) with ESMTP id L2W-Hzz2cHVo for ; Tue, 18 Apr 2017 08:04:57 +0000 (UTC) Received: from mail-io0-f172.google.com (mail-io0-f172.google.com [209.85.223.172]) by mx1-lw-us.apache.org (ASF Mail Server at mx1-lw-us.apache.org) with ESMTPS id 766625F576 for ; Tue, 18 Apr 2017 08:04:57 +0000 (UTC) Received: by mail-io0-f172.google.com with SMTP id o22so59608450iod.3 for ; Tue, 18 Apr 2017 01:04:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to; bh=kr1Np8hVCuyhSCE3SP97r+mzvxroxFa23NQzsaebD24=; b=EGvjB4G9/sH3ptHcqDFgnbNmQShZs2JnZ26jorQyQIk+icflZWCDratEKw5+mRyEJ9 LDxBZ9Q+9/k7XucaP8R4MT+XuuPzPtN8ehYaI2+HVuiY6vm+zWYXub01Bd8lz3l6mgNH pKIPNGPXhmsxS9/acPozXAKDBLRoTbSNzRGCiY12y4iYsFI34GIZgBZaAfy2z22oSiFV Y5uLch7tcomNPOa9rampCJwPVaBgeMC8o3htBJ+h5QpmrKVLBzG3XLQplcN0bgpzd5KN CmV9qVaOKbMdG6cOQISlOLkE7VygzW5eMH/Pzq3gC3S4k59s76oJhYrjdZaxhIXuuCrO 0Nmw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to; bh=kr1Np8hVCuyhSCE3SP97r+mzvxroxFa23NQzsaebD24=; b=Hi0VITNsP9MbQN2/52wrehcG9z8sPVNcw+8lNBtue6KnOGONBbbyPukIItFZo2Wbk6 nLhkxdPM3dUxYz7W9VUpf5FZOXGvqYx4U2n+lLZq+u0Kog0Bw1XZpN3/EAaf8RVfIf85 +cN6nNg16h2YbIrznMgaFeNaeGG8Q+JSk3dmjEoEmMIhgpnJOWVkVA/hD3EtReNDLZqX /hr9d3l/pT0XJh9xLxoFHtiCFlkVdXRicQHw0YPrNDHz0aKSMrnV+wT538ycWxZjYr4T lXLQiI3CICkFDZcfVfzfCIOsVfv6byP1/+fckJFVyB9bHeJTqPJBeHxf8fqMpRyC56kq qiXA== X-Gm-Message-State: AN3rC/5kXCgq+zA8DfGqt4n8D5bxebxkGv3TjM9vxjFeH6Aqlp8+Z9Mt 8wqH7DucxylTr3uZKbegjVgRETLqdA== X-Received: by 10.36.25.139 with SMTP id b133mr12926057itb.0.1492502690963; Tue, 18 Apr 2017 01:04:50 -0700 (PDT) MIME-Version: 1.0 Received: by 10.50.134.228 with HTTP; Tue, 18 Apr 2017 01:04:20 -0700 (PDT) In-Reply-To: References: From: Valentin Kulichenko Date: Tue, 18 Apr 2017 10:04:20 +0200 Message-ID: Subject: Re: Performance vs correctness: I vote fore the second To: dev@ignite.apache.org Content-Type: multipart/alternative; boundary=001a11406686b8a905054d6c5c30 archived-at: Tue, 18 Apr 2017 08:05:01 -0000 --001a11406686b8a905054d6c5c30 Content-Type: text/plain; charset=UTF-8 Can you please elaborate then? What is the logic there? -Val On Tue, Apr 18, 2017 at 9:55 AM, Sergi Vladykin wrote: > Val, > > That discussion has nothing to do with this PRIMARY_SYNC problem. > > Sergi > > 2017-04-18 10:51 GMT+03:00 Valentin Kulichenko < > valentin.kulichenko@gmail.com>: > > > Sergi, > > > > I'm talking about this discussion: > > http://apache-ignite-developers.2346864.n4.nabble. > > com/SQL-on-PARTITIONED-vs-REPLICATED-cache-td16478.html > > > > -Val > > > > On Tue, Apr 18, 2017 at 9:46 AM, Vladimir Ozerov > > wrote: > > > > > Val, > > > > > > PRIMARY_SYNC doesn't work correctly with the most common case of SQL > > query > > > execution over REPLICATED cache. Also it has weird consequences for > > > continuous queries when coupled with another > performance-over-correctness > > > property "readFromBackup=true": user may receive CQ notification with > new > > > value, but subsequent GET on local node may return old value. > > > > > > On Tue, Apr 18, 2017 at 10:42 AM, Valentin Kulichenko < > > > valentin.kulichenko@gmail.com> wrote: > > > > > > > This sounds more like an issue with query execution, rather than > wrong > > > > PRIMARY_SYNC > > > > behavior. We already had a discussion about this optimization in > > > replicated > > > > cache and decided to switch it off by default. > > > > > > > > -Val > > > > > > > > On Tue, Apr 18, 2017 at 9:35 AM, Sergi Vladykin < > > > sergi.vladykin@gmail.com> > > > > wrote: > > > > > > > > > With replicated cache we can execute a query against backup > > partitions > > > > that > > > > > were not updated yet because of PRIMARY_SYNC. Thus we do not see an > > > > update. > > > > > > > > > > Sergi > > > > > > > > > > 2017-04-18 10:30 GMT+03:00 Dmitriy Setrakyan < > dsetrakyan@apache.org > > >: > > > > > > > > > > > Vladimir, > > > > > > > > > > > > What is wrong with a query in PRIMARY_SYNC mode? Why won't it > work? > > > > > > > > > > > > D. > > > > > > > > > > > > On Tue, Apr 18, 2017 at 12:25 AM, Vladimir Ozerov < > > > > vozerov@gridgain.com> > > > > > > wrote: > > > > > > > > > > > > > Folks, > > > > > > > > > > > > > > I received a number of complaints from users that our default > > > setting > > > > > > favor > > > > > > > performance at the cost of correctness and subtle behavior. > > > > Yesterday I > > > > > > > faced one such situation on my own. > > > > > > > > > > > > > > I started REPLICATED cache on several nodes, put some data, > > > executed > > > > > > simple > > > > > > > SQL and got wrong result. No errors, no warnings. The problem > was > > > > > caused > > > > > > by > > > > > > > default PRIMARY_SYNC mode. WTF, our cache doesn't work out of > the > > > > box! > > > > > > > > > > > > > > Another widely known examples are data streamer behavior, "read > > > form > > > > > > > backups" + continuous queries. > > > > > > > > > > > > > > I propose to change our defaults to favor *correctness* over > > > > > performance, > > > > > > > and create good documentation and JavaDocs to explain users how > > to > > > > tune > > > > > > our > > > > > > > product. Proposed changes: > > > > > > > > > > > > > > 1) FULL_SYNC as default; > > > > > > > 2) "readFromBackups=false" as default; > > > > > > > 3) "IgniteDataStreamer.allowOverwrite=true" as default. > > > > > > > > > > > > > > Users should not think how to make Ignite work correctly. It > > should > > > > be > > > > > > > correct out of the box. > > > > > > > > > > > > > > Vladimir. > > > > > > > > > > > > > > > > > > > > > > > > > > > > --001a11406686b8a905054d6c5c30--