re. https://issues.apache.org/jira/browse/TUSCANY-2043

Part of the the fix for this involves removing a FIXME in
org.apache.tuscany.sca.interfacedef.wsdl.xml.XSDModelResolver. Specifically
at the bottom of the aggregate method I need to comment out two lines...


        // FIXME: [rfeng] This is hacky
        //definitions.clear();
        //definitions.add(aggregated);
        return aggregated;

Raymond, do you recall why these were put in?

Because the non-aggregated definition is replaces with the aggregated
definition the effect of including them is to build a hierarchy of XSD that
could end up looking like:

  facade
    facade
      facade
        xsd

depending on how may WSDL/Schema there are in the same namespace.

The other, possibly more dangerous, effect is that some schema are omitted
because the "aggregated" schema may not include all of the schema that are
in the original definitions list, for example, if many schema are in the
same namespace then only the inline schema for WSDL that have been resolved
so far will be present as opposed to all of the XSD that could be available.
So the original list is cleared and replaced with a shortened list. The XSD
that have now been remove will not be resolved.

I get a clean build with these two lines removed, and with the other
required changes in place, so will check my fix in unless someone shouts.

Simon

Reply via email to