Return-Path: X-Original-To: apmail-pig-dev-archive@www.apache.org Delivered-To: apmail-pig-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 EB52011571 for ; Thu, 11 Sep 2014 13:32:34 +0000 (UTC) Received: (qmail 25076 invoked by uid 500); 11 Sep 2014 13:32:34 -0000 Delivered-To: apmail-pig-dev-archive@pig.apache.org Received: (qmail 25031 invoked by uid 500); 11 Sep 2014 13:32:34 -0000 Mailing-List: contact dev-help@pig.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@pig.apache.org Delivered-To: mailing list dev@pig.apache.org Received: (qmail 25014 invoked by uid 500); 11 Sep 2014 13:32:34 -0000 Delivered-To: apmail-hadoop-pig-dev@hadoop.apache.org Received: (qmail 25010 invoked by uid 99); 11 Sep 2014 13:32:34 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 11 Sep 2014 13:32:34 +0000 Date: Thu, 11 Sep 2014 13:32:34 +0000 (UTC) From: "Quang-Nhat HOANG-XUAN (JIRA)" To: pig-dev@hadoop.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Updated] (PIG-4066) An optimization for ROLLUP operation in Pig MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/PIG-4066?page=3Dcom.atlassian.= jira.plugin.system.issuetabpanels:all-tabpanel ] Quang-Nhat HOANG-XUAN updated PIG-4066: --------------------------------------- Attachment: TechnicalNotes.2.pdf > An optimization for ROLLUP operation in Pig > ------------------------------------------- > > Key: PIG-4066 > URL: https://issues.apache.org/jira/browse/PIG-4066 > Project: Pig > Issue Type: Improvement > Reporter: Quang-Nhat HOANG-XUAN > Assignee: Quang-Nhat HOANG-XUAN > Labels: hybrid-irg, optimization, rollup > Attachments: Current Rollup vs Our Rollup.jpg, PIG-4066.2.patch, = PIG-4066.patch, TechnicalNotes.2.pdf, TechnicalNotes.pdf, UserGuide.pdf > > > This patch aims at addressing the current limitation of the ROLLUP operat= or in PIG: most of the work is done in the Map phase of the underlying MapR= educe job to generate all possible intermediate keys that the reducer use t= o aggregate and produce the ROLLUP output. Based on our previous work: =E2= =80=9CDuy-Hung Phan, Matteo Dell=E2=80=99Amico, Pietro Michiardi: On the de= sign space of MapReduce ROLLUP aggregates=E2=80=9D (http://www.eurecom.fr/e= n/publication/4212/download/rs-publi-4212_2.pdf), we show that the design s= pace for a ROLLUP implementation allows for a different approach (in-reduce= r grouping, IRG), in which less work is done in the Map phase and the group= ing is done in the Reduce phase. This patch presents the most efficient imp= lementation we designed (Hybrid IRG), which allows defining a parameter to = balance between parallelism (in the reducers) and communication cost. > This patch contains the following features: > 1. The new ROLLUP approach: IRG, Hybrid IRG. > 2. The PIVOT clause in CUBE operators. > 3. Test cases. > The new syntax to use our ROLLUP approach: > alias =3D CUBE rel BY { CUBE col_ref | ROLLUP col_ref [PIVOT pivot_value]= } [, { CUBE col_ref | ROLLUP col_ref [PIVOT pivot_value]}...] > In case there is multiple ROLLUP operator in one CUBE clause, the last RO= LLUP operator will be executed with our approach (IRG, Hybrid IRG) while th= e remaining ROLLUP ahead will be executed with the default approach. > We have already made some experiments for comparison between our ROLLUP i= mplementation and the current ROLLUP. More information can be found at here= : http://hxquangnhat.github.io/PIG-ROLLUP-H2IRG/ > Patch can be reviewed at here: https://reviews.apache.org/r/23804/ -- This message was sent by Atlassian JIRA (v6.3.4#6332)