You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@pig.apache.org by "Cheolsoo Park (JIRA)" <ji...@apache.org> on 2012/12/03 05:03:58 UTC

[jira] [Commented] (PIG-2815) class loader management in PigContext

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

Cheolsoo Park commented on PIG-2815:
------------------------------------

It seems that the patch is committed to 0.11/trunk but not to 0.9/0.10.

Please let me know if anyone wants this to be committed to 0.9/0.10. Or I will close the jira.

Thanks!
                
> class loader management in PigContext
> -------------------------------------
>
>                 Key: PIG-2815
>                 URL: https://issues.apache.org/jira/browse/PIG-2815
>             Project: Pig
>          Issue Type: Bug
>          Components: impl
>    Affects Versions: 0.9.0
>            Reporter: Raghu Angadi
>            Assignee: Raghu Angadi
>             Fix For: 0.11
>
>         Attachments: PIG-2815-branch-0.9.patch, PIG-2815-branch-0.9.patch, PIG-2815.patch, PIG-2815.patch
>
>
> The way {{PigContext.classloader}} and resolveClassName() are managed can lead to strange class loading issues, especially when not all {{register}} statements are at the top (example in the first comment).
> Two factors contribute to this: sometimes only one of them and sometimes together:
>  # a new classloader (CL) is created after registering each jar.
>     ** but the new jar's parent is the root CL rather than previous CL, effectively throwing previous CL away.
>  # resolveClassName() caches classes based on just the name
>     ** A class is not defined by name alone. Classes loaded by two different unrelated CLs are different objects even if both extract the class from same physical jar file.
>     ** because of (1), the cached class is not necessarily same as the class that would be loaded based on 'current' CL
> having different class objects for same class have many subtle side effects. e.g. there would be two instances of static variables. 
> I think both should be fixed.. thought fixing one of them might be good enough in many cases. I will add a patch.
>        

--
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

Re: PIG Reference Project for Learning Purposes

Posted by Jonathan Coveney <jc...@gmail.com>.
Hey Adarsh!

I would recommend going through the open, but uncompleted JIRA's for Pig.
If one looks like something you can tackle, we're all willing to help out.

Jon


2012/12/2 Adarsh Sastry <ad...@yahoo.com>

> Hello:
> I am new to HADOOP. I had gone through and practiced various topics and
> basic exercises given in the PIG text book. I am looking for a project to
> do as a POC and get a much thorough understanding of PIGLatin. Can any one
> point me to any blog or site which has information & data about a project
> thats already implemented or designed for learners.
>
> Any help will be greatly appeciated.
>
> Rgds
> Adarsh

PIG Reference Project for Learning Purposes

Posted by Adarsh Sastry <ad...@yahoo.com>.
Hello:
I am new to HADOOP. I had gone through and practiced various topics and basic exercises given in the PIG text book. I am looking for a project to do as a POC and get a much thorough understanding of PIGLatin. Can any one point me to any blog or site which has information & data about a project thats already implemented or designed for learners. 
 
Any help will be greatly appeciated.
 
Rgds
Adarsh