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 3A21B18099 for ; Mon, 19 Oct 2015 17:44:12 +0000 (UTC) Received: (qmail 26155 invoked by uid 500); 19 Oct 2015 17:44:11 -0000 Delivered-To: apmail-drill-dev-archive@drill.apache.org Received: (qmail 25105 invoked by uid 500); 19 Oct 2015 17:44:10 -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 24819 invoked by uid 99); 19 Oct 2015 17:44:06 -0000 Received: from arcas.apache.org (HELO arcas) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 19 Oct 2015 17:44:06 +0000 Received: from arcas.apache.org (localhost [127.0.0.1]) by arcas (Postfix) with ESMTP id 233892C1F6E for ; Mon, 19 Oct 2015 17:44:05 +0000 (UTC) Date: Mon, 19 Oct 2015 17:44:05 +0000 (UTC) From: "Deneche A. Hakim (JIRA)" To: dev@drill.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Created] (DRILL-3952) Improve Window Functions performance when not all batches are required to process the current batch MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 Deneche A. Hakim created DRILL-3952: --------------------------------------- Summary: Improve Window Functions performance when not all batches are required to process the current batch Key: DRILL-3952 URL: https://issues.apache.org/jira/browse/DRILL-3952 Project: Apache Drill Issue Type: Bug Components: Execution - Relational Operators Affects Versions: 1.2.0 Reporter: Deneche A. Hakim Assignee: Deneche A. Hakim Fix For: 1.3.0 Currently, the window operator blocks until all batches of current partition to be available. For some queries it's necessary (e.g. aggregate with no order-by in the window definition), but for other cases the window operator can process and pass the current batch downstream sooner. Implementing this should help the window operator use less memory and run faster, especially in the presence of a limit operator. The purpose of this JIRA is to improve the window operator in the following cases: - aggregate, when order-by clause is available in window definition, can process current batch as soon as it receives the last peer row - lead can process current batch as soon as it receives 1 more batch - lag can process current batch immediately - first_value can process current batch immediately - last_value, when order-by clause is available in window definition, can process current batch as soon as it receives the last peer row - row_number, rank and dense_rank can process current batch immediately -- This message was sent by Atlassian JIRA (v6.3.4#6332)