tuscany-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jean-Sebastien Delfino <jsdelf...@apache.org>
Subject Re: Defining WSDL to SDO
Date Fri, 03 Mar 2006 00:10:55 GMT
Jean-Sebastien Delfino wrote:
> ant elder wrote:
>> For the new Axis2 based WS binding we need to get WSDL defined to SDO so
>> that the SOAP Body XML can be (de)serialized to DataObjects 
>> correctly. Could
>> that happen when the import.wsdl in the sca.module is being 
>> processed? Thats
>> done by org.apache.tuscany.model.assembly.impl.AggregateImpl in the
>> initialize method. Adding the following line just after the
>> getAssemblyLoader().loadDefinition call seems to work:
>>                     XSDHelper.INSTANCE.define(url.openStream(), null);
>> Would this be ok?
>> Thanks,
>>    ...ant
> Yes I think this is OK. If your service is flowing complex types and 
> you have generated SDO classes then you just need one of the 
> components in your application module to reference the generated SDO 
> Factory to trigger the initialization of the metadata for your complex 
> types. But in scenarios flowing elements of simple types e.g. <element 
> name="getGreetings" type="xsd:string"> you won't have generated SDO 
> classes so you definitely need to invoke 
> XSDHelper.INSTANCE.define(url.openStream(), null) to get the metadata 
> for your elements in place.
I have a set of related SDO questions - and depending on the answers we 
may have a problem or not :)

Let's say that at build time I give x.wsdl to the SDO code generator. I 
get SDO classes generated for the XSD types defined in my WSDL <types> 
section . Then at runtime I want to use these SDO classes in an SCA 
component. To trigger the initialization of the SDO metadata for these 
types I simply reference the generated factory or use 
SDOUtil.registerStaticTypes(...) when my SCA component starts. Then 
Ant's Axis2 Entry Point runtime does XSDHelper.INSTANCE.define(the exact 
same x.wsdl)... My understanding is that this will dynamically generate 
SDO metadata from the given WSDL..

Which version of the metadata is the SDO runtime going to use? the first 
one that gets registered? the last one? Is XSDHelper going to detect 
that already have SDO metadata registered with static types for the 
given namespace? Do we get new SDO metadata each time we invoke 


View raw message