You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tuscany.apache.org by "Raymond Feng (JIRA)" <de...@tuscany.apache.org> on 2008/08/29 01:11:45 UTC

[jira] Resolved: (TUSCANY-2558) Generated WSDL fails to resolve when packaged in contribution

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

Raymond Feng resolved TUSCANY-2558.
-----------------------------------

    Resolution: Fixed

I think I have fixed the type attribute issue as part of TUSCANY-2398 under rr689587. Can you verify?

> Generated WSDL fails to resolve when packaged in contribution 
> --------------------------------------------------------------
>
>                 Key: TUSCANY-2558
>                 URL: https://issues.apache.org/jira/browse/TUSCANY-2558
>             Project: Tuscany
>          Issue Type: Bug
>    Affects Versions: Java-SCA-1.3
>            Reporter: Lou Amodeo
>            Assignee: Ramkumar Ramalingam
>             Fix For: Java-SCA-Next
>
>         Attachments: calculator.CalculatorService.wsdl, calculator.zip, TUSCANY-2558.patch
>
>
> I attempted to package a WSDL in a contribution that was previously generated using the WSDL deployment process of binding.ws  and received a ContributionException with the following cause: 
> org.apache.tuscany.sca.interfacedef.wsdl.impl.InvalidWSDLException: The fault message MUST have a single part .  
> In this case I was attempting to use interface.wsdl with empty binding.ws with the following SCDL: 
> <?xml version="1.0" encoding="UTF-8"?>
> <composite xmlns="http://www.osoa.org/xmlns/sca/1.0"
>            targetNamespace="http://www.ibm.com/samples/sca/calculator"
>            name="CalculatorLocatorComposite">
>     <component name="CalculatorLocatorComponent">
>       <implementation.java class="calculator.CalculatorLocatorImpl"/>
>             <reference name="calculator" target="CalculatorComponent">
>         <interface.wsdl interface="http://calculator/#wsdl.interface(CalculatorService)"/>
>         <binding.ws/>
>       </reference>
>     </component>
> </composite>
> The failure occurs during  wsdlFactory.createWSDLInterface in WSDLInterfaceProcessor
> private WSDLInterface resolveWSDLInterface(WSDLInterface wsdlInterface, ModelResolver resolver) throws ContributionResolveException {
>         if (wsdlInterface != null && wsdlInterface.isUnresolved()) {
>             // Resolve the WSDL interface
>             wsdlInterface = resolver.resolveModel(WSDLInterface.class, wsdlInterface);
>             if (wsdlInterface.isUnresolved()) {
>                 // If the WSDL interface has never been resolved yet, do it now
>                 // First, resolve the WSDL definition for the given namespace
>                 WSDLDefinition wsdlDefinition = wsdlFactory.createWSDLDefinition();
>                 wsdlDefinition.setUnresolved(true);
>                 wsdlDefinition.setNamespace(wsdlInterface.getName().getNamespaceURI());
>                 WSDLDefinition resolved = resolver.resolveModel(WSDLDefinition.class, wsdlDefinition);
>                 if (!resolved.isUnresolved()) {
>                     wsdlDefinition.setDefinition(resolved.getDefinition());
>                     wsdlDefinition.setLocation(resolved.getLocation());
>                     wsdlDefinition.setURI(resolved.getURI());
>                     wsdlDefinition.getImportedDefinitions().addAll(resolved.getImportedDefinitions());
>                     wsdlDefinition.getXmlSchemas().addAll(resolved.getXmlSchemas());
>                     wsdlDefinition.setUnresolved(false);
>                     WSDLObject<PortType> portType = wsdlDefinition.getWSDLObject(PortType.class, wsdlInterface.getName());
>                     if (portType != null) {                        
>                         // Introspect the WSDL portType and add the resulting
>                         // WSDLInterface to the resolver
>                         try {
>                             wsdlDefinition.setDefinition(portType.getDefinition());
>                             wsdlInterface = wsdlFactory.createWSDLInterface(portType.getElement(), wsdlDefinition, resolver);
>                             wsdlInterface.setWsdlDefinition(wsdlDefinition);
>                             resolver.addModel(wsdlInterface);
>                         } catch (InvalidInterfaceException e) {
>                         	ContributionResolveException ce = new ContributionResolveException(e);
>                         	error("ContributionResolveException", wsdlFactory, ce);
>                             //throw ce;
>                         }                        
>                     }
>   
> I am attaching the generated WSDL.   

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