[ 
https://issues.apache.org/jira/browse/TUSCANY-1352?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Kelvin Goodson resolved TUSCANY-1352.
-------------------------------------

    Resolution: Fixed

Applied Ron's fix, thanks.

> NPE in 
> SDOXSDEcoreBuilder.XSDSchemaAdapterFactoryImpl.SchemaLocator.locateSchema
> --------------------------------------------------------------------------------
>
>                 Key: TUSCANY-1352
>                 URL: https://issues.apache.org/jira/browse/TUSCANY-1352
>             Project: Tuscany
>          Issue Type: Bug
>          Components: Java SDO Implementation
>    Affects Versions: Java-SDO-Next
>            Reporter: Ron Gavlin
>            Priority: Critical
>
> While attempting to use Tuscany DAS with the latest Tuscany SDO, I triggered 
> a NPE in the recently added 
> SDOXSDEcoreBuilder.XSDSchemaAdapterFactoryImpl.SchemaLocator.locateSchema 
> method. The problem occurs when the DAS ConfigUtil.loadConfig method is 
> invoked which causes the SDO runtime to try and locate the "sdoJava.xsd" 
> schema. This schema has a null targetNamespace which triggers the NPE. The 
> required code change is as follows:
> ... (SDOXSDEcoreBuilder.java line 809)
> /* OLD */
>             XSDSchema schema = (XSDSchema)iter.next();
>             if (schema.getTargetNamespace().equals(namespaceURI))
>             {
>               return schema;
>             }
> /* NEW */
>             XSDSchema schema = (XSDSchema)iter.next();
>             String targetNamespace = schema.getTargetNamespace();
>             if (targetNamespace != null && 
> targetNamespace.equals(namespaceURI))
>             {
>               return schema;
>             }
> Would someone please apply the above patch which allows Tuscany DAS to once 
> again work with the Tuscany SDO head? If I have some time in the next few 
> days, I'll try to add a test method to JiraTestCases.java that attempts to 
> "reproduce the problem"/"verify the fix".
> Thanks,
> - Ron

-- 
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: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to