Return-Path: X-Original-To: apmail-pig-commits-archive@www.apache.org Delivered-To: apmail-pig-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 6A46111316 for ; Wed, 25 Jun 2014 05:55:55 +0000 (UTC) Received: (qmail 47066 invoked by uid 500); 25 Jun 2014 05:55:55 -0000 Delivered-To: apmail-pig-commits-archive@pig.apache.org Received: (qmail 47032 invoked by uid 500); 25 Jun 2014 05:55:55 -0000 Mailing-List: contact commits-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 commits@pig.apache.org Received: (qmail 47022 invoked by uid 99); 25 Jun 2014 05:55:55 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 25 Jun 2014 05:55:55 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 25 Jun 2014 05:55:56 +0000 Received: from eris.apache.org (localhost [127.0.0.1]) by eris.apache.org (Postfix) with ESMTP id 174192388A02; Wed, 25 Jun 2014 05:55:31 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r1605272 - in /pig/trunk: CHANGES.txt test/org/apache/pig/impl/streaming/TestPigStreamingUDF.java test/org/apache/pig/test/TestPigStreaming.java Date: Wed, 25 Jun 2014 05:55:30 -0000 To: commits@pig.apache.org From: daijy@apache.org X-Mailer: svnmailer-1.0.9 Message-Id: <20140625055531.174192388A02@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Author: daijy Date: Wed Jun 25 05:55:30 2014 New Revision: 1605272 URL: http://svn.apache.org/r1605272 Log: PIG-4024: TestPigStreamingUDF and TestPigStreaming fail on IBM JDK Modified: pig/trunk/CHANGES.txt pig/trunk/test/org/apache/pig/impl/streaming/TestPigStreamingUDF.java pig/trunk/test/org/apache/pig/test/TestPigStreaming.java Modified: pig/trunk/CHANGES.txt URL: http://svn.apache.org/viewvc/pig/trunk/CHANGES.txt?rev=1605272&r1=1605271&r2=1605272&view=diff ============================================================================== --- pig/trunk/CHANGES.txt (original) +++ pig/trunk/CHANGES.txt Wed Jun 25 05:55:30 2014 @@ -40,6 +40,8 @@ OPTIMIZATIONS BUG FIXES +PIG-4024: TestPigStreamingUDF and TestPigStreaming fail on IBM JDK (ahireanup via daijy) + PIG-4023: BigDec/Int sort is broken (ahireanup via daijy) PIG-4003: Error is thrown by JobStats.getOutputSize() when storing to a Hive table (cheolsoo) Modified: pig/trunk/test/org/apache/pig/impl/streaming/TestPigStreamingUDF.java URL: http://svn.apache.org/viewvc/pig/trunk/test/org/apache/pig/impl/streaming/TestPigStreamingUDF.java?rev=1605272&r1=1605271&r2=1605272&view=diff ============================================================================== --- pig/trunk/test/org/apache/pig/impl/streaming/TestPigStreamingUDF.java (original) +++ pig/trunk/test/org/apache/pig/impl/streaming/TestPigStreamingUDF.java Wed Jun 25 05:55:30 2014 @@ -19,7 +19,7 @@ package org.apache.pig.impl.streaming; import java.io.IOException; import java.util.ArrayList; -import java.util.HashMap; +import java.util.TreeMap; import java.util.List; import java.util.Map; @@ -159,7 +159,7 @@ public class TestPigStreamingUDF { @Test public void testSerialize__map() throws IOException { Tuple t =tf.newTuple(1); - Map m = new HashMap(); + Map m = new TreeMap(); m.put("A", "B"); m.put("C", "D"); t.set(0,m); @@ -170,16 +170,16 @@ public class TestPigStreamingUDF { @Test public void testSerialize__complex_map() throws IOException { Tuple t = tf.newTuple(1); - Map inner_map = new HashMap(); + Map inner_map = new TreeMap(); inner_map.put("A", 1); inner_map.put("B", "E"); - Map outer_map = new HashMap(); + Map outer_map = new TreeMap(); outer_map.put("C", "F"); outer_map.put("D", inner_map); t.set(0,outer_map); - byte[] expectedOutput = "|[_CD#|[_CA#I1|,_CB#CE|]_|,_CC#CF|]_|_\n".getBytes(); + byte[] expectedOutput = "|[_CC#CF|,_CD#|[_CA#I1|,_CB#CE|]_|]_|_\n".getBytes(); Assert.assertTrue(assertEquals(expectedOutput, ps.serializeToBytes(t))); } @@ -360,7 +360,7 @@ public class TestPigStreamingUDF { PigStreamingUDF sp = new PigStreamingUDF(fs); - Map expectedOutput = new HashMap(); + Map expectedOutput = new TreeMap(); expectedOutput.put("A", "B"); expectedOutput.put("C", "D"); Modified: pig/trunk/test/org/apache/pig/test/TestPigStreaming.java URL: http://svn.apache.org/viewvc/pig/trunk/test/org/apache/pig/test/TestPigStreaming.java?rev=1605272&r1=1605271&r2=1605272&view=diff ============================================================================== --- pig/trunk/test/org/apache/pig/test/TestPigStreaming.java (original) +++ pig/trunk/test/org/apache/pig/test/TestPigStreaming.java Wed Jun 25 05:55:30 2014 @@ -20,7 +20,7 @@ package org.apache.pig.test; import java.io.IOException; import java.util.ArrayList; -import java.util.HashMap; +import java.util.TreeMap; import java.util.List; import java.util.Map; @@ -135,7 +135,7 @@ public class TestPigStreaming extends Te @Test public void testSerialize__map() throws IOException { Tuple t = tf.newTuple(1); - Map m = new HashMap(); + Map m = new TreeMap(); m.put("A", "B"); m.put("C", "D"); t.set(0,m); @@ -147,16 +147,16 @@ public class TestPigStreaming extends Te @Test public void testSerialize__complex_map() throws IOException { Tuple t = tf.newTuple(1); - Map inner_map = new HashMap(); + Map inner_map = new TreeMap(); inner_map.put("A", 1); inner_map.put("B", "E"); - Map outer_map = new HashMap(); + Map outer_map = new TreeMap(); outer_map.put("C", "F"); outer_map.put("D", inner_map); t.set(0,outer_map); - byte[] expectedOutput = "[D#[A#1,B#E],C#F]\n".getBytes(); + byte[] expectedOutput = "[C#F,D#[A#1,B#E]]\n".getBytes(); byte[] output = ps.serialize(t); Assert.assertArrayEquals(expectedOutput, output); }