Return-Path: X-Original-To: apmail-drill-dev-archive@www.apache.org Delivered-To: apmail-drill-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 08691179B0 for ; Thu, 26 Mar 2015 04:34:29 +0000 (UTC) Received: (qmail 8317 invoked by uid 500); 26 Mar 2015 04:34:19 -0000 Delivered-To: apmail-drill-dev-archive@drill.apache.org Received: (qmail 8260 invoked by uid 500); 26 Mar 2015 04:34:19 -0000 Mailing-List: contact dev-help@drill.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@drill.apache.org Delivered-To: mailing list dev@drill.apache.org Received: (qmail 8248 invoked by uid 500); 26 Mar 2015 04:34:19 -0000 Delivered-To: apmail-incubator-drill-dev@incubator.apache.org Received: (qmail 8243 invoked by uid 99); 26 Mar 2015 04:34:19 -0000 Received: from reviews-vm.apache.org (HELO reviews.apache.org) (140.211.11.40) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 26 Mar 2015 04:34:19 +0000 Received: from reviews.apache.org (localhost [127.0.0.1]) by reviews.apache.org (Postfix) with ESMTP id 4235F1D52AF; Thu, 26 Mar 2015 04:34:18 +0000 (UTC) Content-Type: multipart/alternative; boundary="===============1532662756301812849==" MIME-Version: 1.0 Subject: Re: Review Request 32523: DRILL-2568: Conditionally drop filter during partition pruning From: "Aman Sinha" To: "Jacques Nadeau" Cc: "Aman Sinha" , "drill" Date: Thu, 26 Mar 2015 04:34:18 -0000 Message-ID: <20150326043418.1505.76941@reviews.apache.org> X-ReviewBoard-URL: https://reviews.apache.org/ Auto-Submitted: auto-generated Sender: "Aman Sinha" X-ReviewGroup: drill-git X-ReviewRequest-URL: https://reviews.apache.org/r/32523/ X-Sender: "Aman Sinha" References: <20150326040853.15432.31879@reviews.apache.org> In-Reply-To: <20150326040853.15432.31879@reviews.apache.org> Reply-To: "Aman Sinha" X-ReviewRequest-Repository: drill-git --===============1532662756301812849== MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit > On March 26, 2015, 4:08 a.m., Jacques Nadeau wrote: > > exec/java-exec/src/main/java/org/apache/drill/exec/planner/logical/partition/PruneScanRule.java, line 271 > > > > > > Shouldn't this be a new filter with the newCondition if canDropFilter and only include full filter in case that !canDropFilter? We need to check for both canDropFilter and newCondition.isAlwaysTrue (this indicates all conjuncts were pushed). We never create a new FilterRel with new conditions - we always either copy the existing FilterRel or drop it completely. - Aman ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/32523/#review77861 ----------------------------------------------------------- On March 26, 2015, 3:49 a.m., Aman Sinha wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/32523/ > ----------------------------------------------------------- > > (Updated March 26, 2015, 3:49 a.m.) > > > Review request for drill and Jacques Nadeau. > > > Bugs: DRILL-2568 > https://issues.apache.org/jira/browse/DRILL-2568 > > > Repository: drill-git > > > Description > ------- > > Drop the filter plan node if all conjuncts in the filter have been pushed as part of partition pruning, except for the situation where the new set of files is empty - we add a single file in that case, so the Filter is preserved in that case. > > > Diffs > ----- > > exec/java-exec/src/main/java/org/apache/drill/exec/planner/logical/partition/PruneScanRule.java b8c9ebf > exec/java-exec/src/test/java/org/apache/drill/exec/expr/TestPrune.java d15555e > > Diff: https://reviews.apache.org/r/32523/diff/ > > > Testing > ------- > > Manual inspection of Explain plans for several types of queries. Running regression tests.. > > > Thanks, > > Aman Sinha > > --===============1532662756301812849==--