You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@felix.apache.org by "Sahoo (JIRA)" <ji...@apache.org> on 2009/05/29 18:28:45 UTC

[jira] Created: (FELIX-1190) Set parent classloader of bundle classloader to be same as what is actually used for delegation

Set parent classloader of bundle classloader to be same as what is actually used for delegation
-----------------------------------------------------------------------------------------------

                 Key: FELIX-1190
                 URL: https://issues.apache.org/jira/browse/FELIX-1190
             Project: Felix
          Issue Type: Bug
          Components: Framework
    Affects Versions: felix-1.6.1
         Environment: generic
            Reporter: Sahoo


Refer to a previous discussion in dev alias:
http://mail-archives.apache.org/mod_mbox/felix-users/200804.mbox/%3c487a994c0804010552n35fc44eew34b34a1795e14d6f@mail.gmail.com%3e

Currently, although Felix uses the classloader that loads Felix classes as the parent class loader for delegation, it actually sets system class loader as the parent (ClassLoader.getParent()). It is because when it creates a class loader, it does not set any parent, hence the default value is used. The fix should be particularly simple. e.g., get hold of a Felix framework class and use its classloader as the parent.



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


[jira] Commented: (FELIX-1190) Set parent classloader of bundle classloader to be same as what is actually used for delegation

Posted by "Sahoo (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/FELIX-1190?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12714642#action_12714642 ] 

Sahoo commented on FELIX-1190:
------------------------------

I would like this to be addressed in next release instead of waiting till 2.0.0. I don't see the fix being a risky one or causing any compatibility issues. The suggested fix does not class loading for bundles. It just sets the parent (as returned by getDelegate()) same as what is actually used by Felix for delegation.

Thanks,
Sahoo

> Set parent classloader of bundle classloader to be same as what is actually used for delegation
> -----------------------------------------------------------------------------------------------
>
>                 Key: FELIX-1190
>                 URL: https://issues.apache.org/jira/browse/FELIX-1190
>             Project: Felix
>          Issue Type: Bug
>          Components: Framework
>    Affects Versions: felix-1.6.1
>         Environment: generic
>            Reporter: Sahoo
>             Fix For: felix-2.0.0
>
>
> Refer to a previous discussion in dev alias:
> http://mail-archives.apache.org/mod_mbox/felix-users/200804.mbox/%3c487a994c0804010552n35fc44eew34b34a1795e14d6f@mail.gmail.com%3e
> Currently, although Felix uses the classloader that loads Felix classes as the parent class loader for delegation, it actually sets system class loader as the parent (ClassLoader.getParent()). It is because when it creates a class loader, it does not set any parent, hence the default value is used. The fix should be particularly simple. e.g., get hold of a Felix framework class and use its classloader as the parent.

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


[jira] Closed: (FELIX-1190) Set parent classloader of bundle classloader to be same as what is actually used for delegation

Posted by "Richard S. Hall (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/FELIX-1190?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Richard S. Hall closed FELIX-1190.
----------------------------------

    Resolution: Fixed
      Assignee: Richard S. Hall

I will close this issue, but we still need a full solution for RFC 132, which I am tracking with a different issue.

> Set parent classloader of bundle classloader to be same as what is actually used for delegation
> -----------------------------------------------------------------------------------------------
>
>                 Key: FELIX-1190
>                 URL: https://issues.apache.org/jira/browse/FELIX-1190
>             Project: Felix
>          Issue Type: Bug
>          Components: Framework
>    Affects Versions: felix-1.6.1
>         Environment: generic
>            Reporter: Sahoo
>            Assignee: Richard S. Hall
>             Fix For: felix-1.8.1
>
>         Attachments: FELIX-1190.txt
>
>
> Refer to a previous discussion in dev alias:
> http://mail-archives.apache.org/mod_mbox/felix-users/200804.mbox/%3c487a994c0804010552n35fc44eew34b34a1795e14d6f@mail.gmail.com%3e
> Currently, although Felix uses the classloader that loads Felix classes as the parent class loader for delegation, it actually sets system class loader as the parent (ClassLoader.getParent()). It is because when it creates a class loader, it does not set any parent, hence the default value is used. The fix should be particularly simple. e.g., get hold of a Felix framework class and use its classloader as the parent.

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


[jira] Updated: (FELIX-1190) Set parent classloader of bundle classloader to be same as what is actually used for delegation

Posted by "Richard S. Hall (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/FELIX-1190?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Richard S. Hall updated FELIX-1190:
-----------------------------------

    Fix Version/s:     (was: felix-2.0.0)
                   felix-1.8.1

> Set parent classloader of bundle classloader to be same as what is actually used for delegation
> -----------------------------------------------------------------------------------------------
>
>                 Key: FELIX-1190
>                 URL: https://issues.apache.org/jira/browse/FELIX-1190
>             Project: Felix
>          Issue Type: Bug
>          Components: Framework
>    Affects Versions: felix-1.6.1
>         Environment: generic
>            Reporter: Sahoo
>             Fix For: felix-1.8.1
>
>
> Refer to a previous discussion in dev alias:
> http://mail-archives.apache.org/mod_mbox/felix-users/200804.mbox/%3c487a994c0804010552n35fc44eew34b34a1795e14d6f@mail.gmail.com%3e
> Currently, although Felix uses the classloader that loads Felix classes as the parent class loader for delegation, it actually sets system class loader as the parent (ClassLoader.getParent()). It is because when it creates a class loader, it does not set any parent, hence the default value is used. The fix should be particularly simple. e.g., get hold of a Felix framework class and use its classloader as the parent.

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


[jira] Updated: (FELIX-1190) Set parent classloader of bundle classloader to be same as what is actually used for delegation

Posted by "Richard S. Hall (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/FELIX-1190?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Richard S. Hall updated FELIX-1190:
-----------------------------------

    Attachment: FELIX-1190.txt

> Set parent classloader of bundle classloader to be same as what is actually used for delegation
> -----------------------------------------------------------------------------------------------
>
>                 Key: FELIX-1190
>                 URL: https://issues.apache.org/jira/browse/FELIX-1190
>             Project: Felix
>          Issue Type: Bug
>          Components: Framework
>    Affects Versions: felix-1.6.1
>         Environment: generic
>            Reporter: Sahoo
>             Fix For: felix-1.8.1
>
>         Attachments: FELIX-1190.txt
>
>
> Refer to a previous discussion in dev alias:
> http://mail-archives.apache.org/mod_mbox/felix-users/200804.mbox/%3c487a994c0804010552n35fc44eew34b34a1795e14d6f@mail.gmail.com%3e
> Currently, although Felix uses the classloader that loads Felix classes as the parent class loader for delegation, it actually sets system class loader as the parent (ClassLoader.getParent()). It is because when it creates a class loader, it does not set any parent, hence the default value is used. The fix should be particularly simple. e.g., get hold of a Felix framework class and use its classloader as the parent.

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


[jira] Updated: (FELIX-1190) Set parent classloader of bundle classloader to be same as what is actually used for delegation

Posted by "Richard S. Hall (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/FELIX-1190?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Richard S. Hall updated FELIX-1190:
-----------------------------------

    Fix Version/s: felix-2.0.0

> Set parent classloader of bundle classloader to be same as what is actually used for delegation
> -----------------------------------------------------------------------------------------------
>
>                 Key: FELIX-1190
>                 URL: https://issues.apache.org/jira/browse/FELIX-1190
>             Project: Felix
>          Issue Type: Bug
>          Components: Framework
>    Affects Versions: felix-1.6.1
>         Environment: generic
>            Reporter: Sahoo
>             Fix For: felix-2.0.0
>
>
> Refer to a previous discussion in dev alias:
> http://mail-archives.apache.org/mod_mbox/felix-users/200804.mbox/%3c487a994c0804010552n35fc44eew34b34a1795e14d6f@mail.gmail.com%3e
> Currently, although Felix uses the classloader that loads Felix classes as the parent class loader for delegation, it actually sets system class loader as the parent (ClassLoader.getParent()). It is because when it creates a class loader, it does not set any parent, hence the default value is used. The fix should be particularly simple. e.g., get hold of a Felix framework class and use its classloader as the parent.

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


[jira] Commented: (FELIX-1190) Set parent classloader of bundle classloader to be same as what is actually used for delegation

Posted by "Richard S. Hall (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/FELIX-1190?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12714545#action_12714545 ] 

Richard S. Hall commented on FELIX-1190:
----------------------------------------

I think this could be addressed in RFC 132. In there, there is some standardization around this. Regardless, we can straighten it out one way or the other.

> Set parent classloader of bundle classloader to be same as what is actually used for delegation
> -----------------------------------------------------------------------------------------------
>
>                 Key: FELIX-1190
>                 URL: https://issues.apache.org/jira/browse/FELIX-1190
>             Project: Felix
>          Issue Type: Bug
>          Components: Framework
>    Affects Versions: felix-1.6.1
>         Environment: generic
>            Reporter: Sahoo
>             Fix For: felix-2.0.0
>
>
> Refer to a previous discussion in dev alias:
> http://mail-archives.apache.org/mod_mbox/felix-users/200804.mbox/%3c487a994c0804010552n35fc44eew34b34a1795e14d6f@mail.gmail.com%3e
> Currently, although Felix uses the classloader that loads Felix classes as the parent class loader for delegation, it actually sets system class loader as the parent (ClassLoader.getParent()). It is because when it creates a class loader, it does not set any parent, hence the default value is used. The fix should be particularly simple. e.g., get hold of a Felix framework class and use its classloader as the parent.

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


[jira] Commented: (FELIX-1190) Set parent classloader of bundle classloader to be same as what is actually used for delegation

Posted by "Richard S. Hall (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/FELIX-1190?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12714662#action_12714662 ] 

Richard S. Hall commented on FELIX-1190:
----------------------------------------

I don't have an issue including this in the maintenance release, but we will still have to run it by everyone to make sure no issues appear as a result. I am heading out for JavaOne tomorrow morning, but I will try to look at while I am there.

> Set parent classloader of bundle classloader to be same as what is actually used for delegation
> -----------------------------------------------------------------------------------------------
>
>                 Key: FELIX-1190
>                 URL: https://issues.apache.org/jira/browse/FELIX-1190
>             Project: Felix
>          Issue Type: Bug
>          Components: Framework
>    Affects Versions: felix-1.6.1
>         Environment: generic
>            Reporter: Sahoo
>             Fix For: felix-1.8.1
>
>
> Refer to a previous discussion in dev alias:
> http://mail-archives.apache.org/mod_mbox/felix-users/200804.mbox/%3c487a994c0804010552n35fc44eew34b34a1795e14d6f@mail.gmail.com%3e
> Currently, although Felix uses the classloader that loads Felix classes as the parent class loader for delegation, it actually sets system class loader as the parent (ClassLoader.getParent()). It is because when it creates a class loader, it does not set any parent, hence the default value is used. The fix should be particularly simple. e.g., get hold of a Felix framework class and use its classloader as the parent.

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


[jira] Commented: (FELIX-1190) Set parent classloader of bundle classloader to be same as what is actually used for delegation

Posted by "Sahoo (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/FELIX-1190?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12715358#action_12715358 ] 

Sahoo commented on FELIX-1190:
------------------------------

Thanks, Richard. Yes, that's what I was hoping as a fix.

> Set parent classloader of bundle classloader to be same as what is actually used for delegation
> -----------------------------------------------------------------------------------------------
>
>                 Key: FELIX-1190
>                 URL: https://issues.apache.org/jira/browse/FELIX-1190
>             Project: Felix
>          Issue Type: Bug
>          Components: Framework
>    Affects Versions: felix-1.6.1
>         Environment: generic
>            Reporter: Sahoo
>             Fix For: felix-1.8.1
>
>         Attachments: FELIX-1190.txt
>
>
> Refer to a previous discussion in dev alias:
> http://mail-archives.apache.org/mod_mbox/felix-users/200804.mbox/%3c487a994c0804010552n35fc44eew34b34a1795e14d6f@mail.gmail.com%3e
> Currently, although Felix uses the classloader that loads Felix classes as the parent class loader for delegation, it actually sets system class loader as the parent (ClassLoader.getParent()). It is because when it creates a class loader, it does not set any parent, hence the default value is used. The fix should be particularly simple. e.g., get hold of a Felix framework class and use its classloader as the parent.

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


[jira] Commented: (FELIX-1190) Set parent classloader of bundle classloader to be same as what is actually used for delegation

Posted by "Richard S. Hall (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/FELIX-1190?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12715116#action_12715116 ] 

Richard S. Hall commented on FELIX-1190:
----------------------------------------

Sahoo, check this one-line patch to make sure it is what you wanted. If so, I will make a snapshot so we can test it in GF. Thanks.

> Set parent classloader of bundle classloader to be same as what is actually used for delegation
> -----------------------------------------------------------------------------------------------
>
>                 Key: FELIX-1190
>                 URL: https://issues.apache.org/jira/browse/FELIX-1190
>             Project: Felix
>          Issue Type: Bug
>          Components: Framework
>    Affects Versions: felix-1.6.1
>         Environment: generic
>            Reporter: Sahoo
>             Fix For: felix-1.8.1
>
>         Attachments: FELIX-1190.txt
>
>
> Refer to a previous discussion in dev alias:
> http://mail-archives.apache.org/mod_mbox/felix-users/200804.mbox/%3c487a994c0804010552n35fc44eew34b34a1795e14d6f@mail.gmail.com%3e
> Currently, although Felix uses the classloader that loads Felix classes as the parent class loader for delegation, it actually sets system class loader as the parent (ClassLoader.getParent()). It is because when it creates a class loader, it does not set any parent, hence the default value is used. The fix should be particularly simple. e.g., get hold of a Felix framework class and use its classloader as the parent.

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