[
https://issues.apache.org/jira/browse/PIG-3359?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Jonathan Packer updated PIG-3359:
---------------------------------
Attachment: PIG-3359_test.tar.gz
A few notes:
PIG-3359_test.tar.gz has a pigscript and other files which test registering
udfs and parameter substitutions inside macros to demonstrate how this works.
I haven't been able to upload my diff to ReviewBoard because I generated it
with git and I think RB wants something svn-specific. Is there some way I can
get git to generate something acceptable?
I haven't written full unit-tests yet; I'd be happy to write them if people are
ok with the code changes in general.
Finally, there was a problem with unrelated classes FieldSchemaResetter and
ExpressionUidResetter which were not declared in their own files, which seemed
to break trunk. I moved the former into its own file since it was used by two
other classes, and the latter into an inner class in UidResetter and that
seemed to fix it. Let me know if anyone has a better idea of what these things
are or where they're supposed to go.
> Register Statements and Param Substitution in Macros
> ----------------------------------------------------
>
> Key: PIG-3359
> URL: https://issues.apache.org/jira/browse/PIG-3359
> Project: Pig
> Issue Type: Bug
> Components: parser
> Reporter: Jonathan Packer
> Assignee: Jonathan Packer
> Attachments: PIG-3359_test.tar.gz, PIG-3359-v1.diff
>
>
> There are some gaps in the functionality of macros that I'll be making a
> patch to address. The goal is to provide everything you'd need to make
> reusable algorithms libraries.
> 1. You can't register udfs inside a macro
> 2. Paramater substitutions aren't done inside macros
> 3. Resources (including macros) should not be redundantly acquired if they
> are already present.
> Rohini's patch https://issues.apache.org/jira/browse/PIG-3204 should address
> problem 3 where Pig reparses everything every time it reads a line, but there
> still would be a problem if two separate files import the same macro / udf
> file.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira