You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tuscany.apache.org by "Yang ZHONG (JIRA)" <tu...@ws.apache.org> on 2007/02/14 00:42:05 UTC

[jira] Created: (TUSCANY-1109) TypeHelperImpl#getType(Class) queries wrong scope (EPackage.Registry.INSTANCE) and misses delegate scopes

TypeHelperImpl#getType(Class) queries wrong scope (EPackage.Registry.INSTANCE) and misses delegate scopes
---------------------------------------------------------------------------------------------------------

                 Key: TUSCANY-1109
                 URL: https://issues.apache.org/jira/browse/TUSCANY-1109
             Project: Tuscany
          Issue Type: Bug
          Components: Java SDO Implementation
    Affects Versions: Java-SDO-Mx
            Reporter: Yang ZHONG
             Fix For: Java-SDO-Mx


TypeHelperImpl#getType(Class) queries wrong scope: EPackage.Registry.INSTANCE.

And TypeHelperImpl#getType(Class) misses delegate scopes, because getRegistry().values() doesn't include delegateRegistry.values().

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


---------------------------------------------------------------------
To unsubscribe, e-mail: tuscany-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: tuscany-dev-help@ws.apache.org


[jira] Resolved: (TUSCANY-1109) TypeHelperImpl#getType(Class) queries wrong scope (EPackage.Registry.INSTANCE) and misses delegate scopes

Posted by "Frank Budinsky (JIRA)" <tu...@ws.apache.org>.
     [ https://issues.apache.org/jira/browse/TUSCANY-1109?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Frank Budinsky resolved TUSCANY-1109.
-------------------------------------

    Resolution: Duplicate

I'm resolving this as a duplicate of TUSCANY-1110, since it will completely replace the current implementation of getType(). 

> TypeHelperImpl#getType(Class) queries wrong scope (EPackage.Registry.INSTANCE) and misses delegate scopes
> ---------------------------------------------------------------------------------------------------------
>
>                 Key: TUSCANY-1109
>                 URL: https://issues.apache.org/jira/browse/TUSCANY-1109
>             Project: Tuscany
>          Issue Type: Bug
>          Components: Java SDO Implementation
>    Affects Versions: Java-SDO-M3
>            Reporter: Yang ZHONG
>             Fix For: Java-SDO-Mx
>
>
> TypeHelperImpl#getType(Class) queries wrong scope: EPackage.Registry.INSTANCE.
> And TypeHelperImpl#getType(Class) misses delegate scopes, because getRegistry().values() doesn't include delegateRegistry.values().

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


---------------------------------------------------------------------
To unsubscribe, e-mail: tuscany-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: tuscany-dev-help@ws.apache.org


[jira] Updated: (TUSCANY-1109) TypeHelperImpl#getType(Class) queries wrong scope (EPackage.Registry.INSTANCE) and misses delegate scopes

Posted by "Kelvin Goodson (JIRA)" <tu...@ws.apache.org>.
     [ https://issues.apache.org/jira/browse/TUSCANY-1109?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Kelvin Goodson updated TUSCANY-1109:
------------------------------------

        Fix Version/s:     (was: Java-SDO-Mx)
                       Java-SDO-M3
    Affects Version/s:     (was: Java-SDO-Mx)
                       Java-SDO-M3

> TypeHelperImpl#getType(Class) queries wrong scope (EPackage.Registry.INSTANCE) and misses delegate scopes
> ---------------------------------------------------------------------------------------------------------
>
>                 Key: TUSCANY-1109
>                 URL: https://issues.apache.org/jira/browse/TUSCANY-1109
>             Project: Tuscany
>          Issue Type: Bug
>          Components: Java SDO Implementation
>    Affects Versions: Java-SDO-M3
>            Reporter: Yang ZHONG
>             Fix For: Java-SDO-M3
>
>
> TypeHelperImpl#getType(Class) queries wrong scope: EPackage.Registry.INSTANCE.
> And TypeHelperImpl#getType(Class) misses delegate scopes, because getRegistry().values() doesn't include delegateRegistry.values().

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


---------------------------------------------------------------------
To unsubscribe, e-mail: tuscany-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: tuscany-dev-help@ws.apache.org


[jira] Commented: (TUSCANY-1109) TypeHelperImpl#getType(Class) queries wrong scope (EPackage.Registry.INSTANCE) and misses delegate scopes

Posted by "Yang ZHONG (JIRA)" <tu...@ws.apache.org>.
    [ https://issues.apache.org/jira/browse/TUSCANY-1109?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12474228 ] 

Yang ZHONG commented on TUSCANY-1109:
-------------------------------------

The SDO spec hasn't described enough scoping details yet. Our impl is currently based on EMF; here's what EMF has been doing:
    EMF has one EPackage.Registry for each ClassLoader, and EPackage.Registry.INSTANCE delegates to current Thread ClassLoader's EPackage.Registry.
    Each EPackage.Registry maps from NameSpace to EPackage, and EPackage maps from name to Type.
    Queries on EPackage.Registry will be executed locally, then delegated to parent ClassLoader EPackage.Registry if no EPackage found for the given NameSpace.

ClassLoader Hierarchy may be complicated, such as J2EE environment. On the other hand, user may also change Thread current ClassLoader. They all affect SDO XSDHelper#define behavior.

TypeHelperImpl#getType(Class) misses parent ClassLoader EPackage.Registry.

> TypeHelperImpl#getType(Class) queries wrong scope (EPackage.Registry.INSTANCE) and misses delegate scopes
> ---------------------------------------------------------------------------------------------------------
>
>                 Key: TUSCANY-1109
>                 URL: https://issues.apache.org/jira/browse/TUSCANY-1109
>             Project: Tuscany
>          Issue Type: Bug
>          Components: Java SDO Implementation
>    Affects Versions: Java-SDO-Mx
>            Reporter: Yang ZHONG
>             Fix For: Java-SDO-Mx
>
>
> TypeHelperImpl#getType(Class) queries wrong scope: EPackage.Registry.INSTANCE.
> And TypeHelperImpl#getType(Class) misses delegate scopes, because getRegistry().values() doesn't include delegateRegistry.values().

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


---------------------------------------------------------------------
To unsubscribe, e-mail: tuscany-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: tuscany-dev-help@ws.apache.org


[jira] Commented: (TUSCANY-1109) TypeHelperImpl#getType(Class) queries wrong scope (EPackage.Registry.INSTANCE) and misses delegate scopes

Posted by "Frank Budinsky (JIRA)" <tu...@ws.apache.org>.
    [ https://issues.apache.org/jira/browse/TUSCANY-1109?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12472934 ] 

Frank Budinsky commented on TUSCANY-1109:
-----------------------------------------

I guess this was broken since we moved to the new HelperContext scoping. We should fix this and use it as the fallback strategy when a more optimized lookup fails to find the type (see TUSCANY-1110).


> TypeHelperImpl#getType(Class) queries wrong scope (EPackage.Registry.INSTANCE) and misses delegate scopes
> ---------------------------------------------------------------------------------------------------------
>
>                 Key: TUSCANY-1109
>                 URL: https://issues.apache.org/jira/browse/TUSCANY-1109
>             Project: Tuscany
>          Issue Type: Bug
>          Components: Java SDO Implementation
>    Affects Versions: Java-SDO-Mx
>            Reporter: Yang ZHONG
>             Fix For: Java-SDO-Mx
>
>
> TypeHelperImpl#getType(Class) queries wrong scope: EPackage.Registry.INSTANCE.
> And TypeHelperImpl#getType(Class) misses delegate scopes, because getRegistry().values() doesn't include delegateRegistry.values().

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


---------------------------------------------------------------------
To unsubscribe, e-mail: tuscany-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: tuscany-dev-help@ws.apache.org


[jira] Commented: (TUSCANY-1109) TypeHelperImpl#getType(Class) queries wrong scope (EPackage.Registry.INSTANCE) and misses delegate scopes

Posted by "Kelvin Goodson (JIRA)" <tu...@ws.apache.org>.
    [ https://issues.apache.org/jira/browse/TUSCANY-1109?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12474146 ] 

Kelvin Goodson commented on TUSCANY-1109:
-----------------------------------------

Yang,
   I see that the code looks a little fragile in the assumption that the delegate registry is the singleton instance,  but as far as I can see this is always the case unless someone is using the TypeHelperImpl constructor directly,  rather than the SDOUtil.createTypeHelper() (now deprecated) or SDOUtil.createHelperContext()  methods.  These are the only references in the impl codebase. Do I understand the issue you are raising correctly?  Is there a demonstrable failure for this? 

> TypeHelperImpl#getType(Class) queries wrong scope (EPackage.Registry.INSTANCE) and misses delegate scopes
> ---------------------------------------------------------------------------------------------------------
>
>                 Key: TUSCANY-1109
>                 URL: https://issues.apache.org/jira/browse/TUSCANY-1109
>             Project: Tuscany
>          Issue Type: Bug
>          Components: Java SDO Implementation
>    Affects Versions: Java-SDO-Mx
>            Reporter: Yang ZHONG
>             Fix For: Java-SDO-Mx
>
>
> TypeHelperImpl#getType(Class) queries wrong scope: EPackage.Registry.INSTANCE.
> And TypeHelperImpl#getType(Class) misses delegate scopes, because getRegistry().values() doesn't include delegateRegistry.values().

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


---------------------------------------------------------------------
To unsubscribe, e-mail: tuscany-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: tuscany-dev-help@ws.apache.org