[ 
https://issues.apache.org/jira/browse/PIG-245?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12605649#action_12605649
 ] 

Alan Gates commented on PIG-245:
--------------------------------

Eventually what we want is for a UDF to be able to return 3 levels of errors:

WARN - I couldn't process this record, so we should put a null here and keep 
going.  This can be communicated by the UDF returning null once we have them.  
Ideally we'd like an explicit return code for this so that we can log a warning.

ERROR - I couldn't process this record and we should give up on this execution 
attempt.  That's the default behavior now, and what we should continue to do 
for now.

FATAL - I couldn't process this record and we should give up the job entirely 
(ie no retries).  This would only be used in cases where we know retries will 
be of no use, for example if we find we have an incompatible version of the UDF 
loaded or something.  There's no way to do this now.

All this is a long way to say that, given we don't yet have nulls, the best we 
can do right now is error out when we get an IOException.

> Need wrapper UDFs for all java.lang.Math functions
> --------------------------------------------------
>
>                 Key: PIG-245
>                 URL: https://issues.apache.org/jira/browse/PIG-245
>             Project: Pig
>          Issue Type: New Feature
>            Reporter: Shravan Matthur Narayanamurthy
>            Assignee: Shravan Matthur Narayanamurthy
>            Priority: Minor
>         Attachments: MathUDF.patch, mathudfs.zip
>
>
> Attached is the code for all the wrapper UDFs for the math functions with 
> unit tests. One exception is the random() function which does not take any 
> argument. Since Pig doesn't support zero argument udfs,  the current code 
> takes a dummy argument which is not used in the call to 
> java.lang.Math.random().

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to