Author: knoguchi
Date: Mon Nov 21 17:33:20 2016
New Revision: 1770726
URL: http://svn.apache.org/viewvc?rev=1770726&view=rev
Log:
PIG-5066: e2e Jython_Checkin_2 failing due to floating precision difference
(knoguchi)
Modified:
pig/trunk/CHANGES.txt
pig/trunk/test/e2e/pig/tests/turing_jython.conf
Modified: pig/trunk/CHANGES.txt
URL:
http://svn.apache.org/viewvc/pig/trunk/CHANGES.txt?rev=1770726&r1=1770725&r2=1770726&view=diff
==============================================================================
--- pig/trunk/CHANGES.txt (original)
+++ pig/trunk/CHANGES.txt Mon Nov 21 17:33:20 2016
@@ -59,6 +59,8 @@ OPTIMIZATIONS
Â
BUG FIXES
+PIG-5066: e2e Jython_Checkin_2 failing due to floating precision difference
(knoguchi)
+
PIG-5063: e2e IOErrors_1 on mapreduce is unstable (knoguchi)
PIG-5062: Allow Native e2e tests to run in parallel (knoguchi)
Modified: pig/trunk/test/e2e/pig/tests/turing_jython.conf
URL:
http://svn.apache.org/viewvc/pig/trunk/test/e2e/pig/tests/turing_jython.conf?rev=1770726&r1=1770725&r2=1770726&view=diff
==============================================================================
--- pig/trunk/test/e2e/pig/tests/turing_jython.conf (original)
+++ pig/trunk/test/e2e/pig/tests/turing_jython.conf Mon Nov 21 17:33:20 2016
@@ -50,7 +50,7 @@ d = filter b by age < 50;
e = cogroup c by (name, age), d by (name, age) ;
f = foreach e generate flatten(c), flatten(d);
g = group f by registration;
-h = foreach g generate group, SUM(f.d::contributions);
+h = foreach g generate group, (float) ROUND(SUM(f.d::contributions) * 100) /
100.0;
i = order h by $1;
store i into '$out';
""").bind({'in1':input1,'in2':input2, 'out':output}).runSingle()
@@ -68,7 +68,7 @@ else:
e = cogroup c by (name, age), d by
(name, age) ;
f = foreach e generate flatten(c),
flatten(d);
g = group f by registration;
- h = foreach g generate group,
SUM(f.d::contributions);
+ h = foreach g generate group, (float)
ROUND(SUM(f.d::contributions) * 100) / 100.0;
i = order h by $1;
store i into ':OUTPATH:';
\,