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 6BA9318DB7 for ; Mon, 11 Jan 2016 06:12:40 +0000 (UTC) Received: (qmail 47582 invoked by uid 500); 11 Jan 2016 06:12:40 -0000 Delivered-To: apmail-pig-dev-archive@pig.apache.org Received: (qmail 47526 invoked by uid 500); 11 Jan 2016 06:12:40 -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 47515 invoked by uid 500); 11 Jan 2016 06:12:40 -0000 Delivered-To: apmail-hadoop-pig-dev@hadoop.apache.org Received: (qmail 47511 invoked by uid 99); 11 Jan 2016 06:12:40 -0000 Received: from arcas.apache.org (HELO arcas) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 11 Jan 2016 06:12:40 +0000 Received: from arcas.apache.org (localhost [127.0.0.1]) by arcas (Postfix) with ESMTP id C56DF2C1F57 for ; Mon, 11 Jan 2016 06:12:39 +0000 (UTC) Date: Mon, 11 Jan 2016 06:12:39 +0000 (UTC) From: "Rohini Palaniswamy (JIRA)" To: pig-dev@hadoop.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (PIG-4773) [Pig on Tez] Secondary key descending sort in nested foreach after union does ascending instead MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/PIG-4773?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15091488#comment-15091488 ] Rohini Palaniswamy commented on PIG-4773: ----------------------------------------- bq. Do we need to set "pig.secondarySortOrder" again at vertex level? We already set it at edge level. Main reason for setting it at vertex level is for comparator intialization in POShuffleTezLoad. POShuffleTezLoad makes use of comparator for key comparison for multiple inputs. Even though we don't have the case of multiple inputs (cogroup) with SecondaryKeyComparison now which is the code path in which it will be exercised, added it now itself to avoid missing that in future and added a TODO. > [Pig on Tez] Secondary key descending sort in nested foreach after union does ascending instead > ----------------------------------------------------------------------------------------------- > > Key: PIG-4773 > URL: https://issues.apache.org/jira/browse/PIG-4773 > Project: Pig > Issue Type: Bug > Components: tez > Reporter: Rohini Palaniswamy > Assignee: Rohini Palaniswamy > Fix For: 0.16.0 > > Attachments: PIG-4773-1.patch, PIG-4773-2.patch > > > PigSecondaryKeyComparator does not implement a compare(WritableComparable a, WritableComparable b) method. In case of OrderedGroupedMergedKVInput with vertex groups, object comparison instead of byte comparison is done when merging the multiple inputs into one. Since the compare API is not overridden, WritableComparator compare API is called and the value types are directly compared which means it is always ascending. -- This message was sent by Atlassian JIRA (v6.3.4#6332)