[ 
https://issues.apache.org/jira/browse/PIG-3679?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Cheolsoo Park updated PIG-3679:
-------------------------------

    Attachment: PIG-3679-4.patch

I am uploading yet another patch that fixes the e2e test. This time, I took 
Daniel's patch and added a null check to the exec() of StreamingUDF.

On a second thought about backward incompatibility of PIG-3568, looks like 
we're safe with changing POUserFunc to filter out nulls for the following 
reasons-
# The changes in all the other PO operators except POUserFunc should be 
transparent to users because in the end, the result remains unchanged. The only 
difference is whether nulls travel the full or part of pipeline.
# Since POUserFunc now filters out nulls, some UDFs that used to throw NPE will 
no longer throw NPE (e.g. DoubleRound). But this is more of an improvement than 
an backward incompatible change.

So I will commit PIG-3679-4.patch if there is no objection. Thanks!


> e2e StreamingPythonUDFs_10 fails in trunk
> -----------------------------------------
>
>                 Key: PIG-3679
>                 URL: https://issues.apache.org/jira/browse/PIG-3679
>             Project: Pig
>          Issue Type: Bug
>            Reporter: Cheolsoo Park
>            Assignee: Cheolsoo Park
>             Fix For: 0.13.0
>
>         Attachments: PIG-3679-1.patch, PIG-3679-2.patch, PIG-3679-3.patch, 
> PIG-3679-4.patch
>
>
> The e2e test StreamingPythonUDFs_10 fails in trunk with NPE-
> {code}
> Caused by: java.lang.NullPointerException
>         at org.apache.pig.builtin.DoubleRound.exec(DoubleRound.java:45)
> {code}
> The test query is as follows-
> {code}
> a = load '/user/pig/tests/data/singlefile/allscalar10k' using PigStorage() as 
> (name:chararray, age:int, gpa:double, instate:chararray);
> b = foreach a generate name, 
> ((double)ROUND((instate=='true'?gpa:gpa+1)*10000)) / 10000.0;
> store b into 
> '/user/pig/out/cheolsoop-1390330024-nightly.conf-StreamingPythonUDFs/StreamingPythonUDFs_10_benchmark.out';
> {code}



--
This message was sent by Atlassian JIRA
(v6.1.5#6160)

Reply via email to