Wrong namespaces in WSDL - 2.2.6 OK, 2.2.7 and 2.2.8 BROKEN
-----------------------------------------------------------

                 Key: CXF-2810
                 URL: https://issues.apache.org/jira/browse/CXF-2810
             Project: CXF
          Issue Type: Bug
          Components: Aegis Databinding, Core
    Affects Versions: 2.2.8, 2.2.7
            Reporter: Jara Cesnek
            Priority: Blocker


In WSDL there is wrong namespaces on arguments.
Version 2.2.6 and below is OK, 2.2.7 and 2.2.8 generate invalid WSDL.

2.2.6 OK
{code}
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"; 
xmlns:v2="http://v2_0_0.smlouva.ws.aa.marbes.cz"; >
   <soapenv:Header/>
   <soapenv:Body>
      <v2:updateSmlouvy>
         <v2:smlouva>

            <v2:cenaKupni>?</v2:cenaKupni>

            <v2:dodatkyKeSmlouve>
               <v2:AaSmlouvaDodatek>
                  <v2:zadavaciDok>?</v2:zadavaciDok>
                  <v2:zakon>?</v2:zakon>
               </v2:AaSmlouvaDodatek>
            </v2:dodatkyKeSmlouve>

         </v2:smlouva>
         <v2:idempotentGuid>?</v2:idempotentGuid>
      </v2:updateSmlouvy>
   </soapenv:Body>
</soapenv:Envelope>
{code}

2.2.7 WRONG - there is "wo" namespace from java package
{code}
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"; 
xmlns:v2="http://v2_0_0.smlouva.ws.aa.marbes.cz"; 
xmlns:wo="http://wo.v2_0_0.ws.smlouva.modules.aa.modules.daisy.marbes.cz";>
   <soapenv:Header/>
   <soapenv:Body>
      <v2:updateSmlouvy>
         <v2:smlouva>

            <wo:cenaKupni>?</wo:cenaKupni>

            <wo:dodatkyKeSmlouve>
               <v2:AaSmlouvaDodatek>
                  <v2:zadavaciDok>?</v2:zadavaciDok>
                  <v2:zakon>?</v2:zakon>
               </v2:AaSmlouvaDodatek>
            </wo:dodatkyKeSmlouve>

         </v2:smlouva>
         <v2:idempotentGuid>?</v2:idempotentGuid>
      </v2:updateSmlouvy>
   </soapenv:Body>
</soapenv:Envelope>
{code}

If I call WS from SOAPUI, all values shows as NULL. When I modify SOAPUI XML - 
replace wo with v2 - WS start working.

*So CXF expects "v2" namespace in request XML, but in WSDL generate "wo" 
namespace.*

Server code:
{code}
        JaxWsServerFactoryBean serverFactoryBean = new JaxWsServerFactoryBean();
        serverFactoryBean.setServiceClass(AopUtils.getTargetClass(implementor));
        serverFactoryBean.setServiceBean(implementor);
        serverFactoryBean.setDataBinding(new AegisDatabinding());
        serverFactoryBean.setAddress(url);
        serverFactoryBean.setBus(cxfServlet.getBus());
        serverFactoryBean.create();
{code}

Interface:
{code}
@WebService(name = "aa_smlouva_v2_0_0", targetNamespace = 
"http://v2_0_0.smlouva.ws.aa.marbes.cz";)
public interface AaSmlouvaWS {

    @WebMethod
    public WOrepeatable_result updateSmlouvy (
            @WebParam(name = "smlouva")  WOAaSmlouva smlouva, 
            @WebParam(name = "idempotentGuid")  String idempotentGuid
    );
}

@org.apache.cxf.aegis.type.java5.XmlType(name = "AaSmlouva", namespace = 
"http://v2_0_0.smlouva.ws.aa.marbes.cz";)
public class WOAaSmlouva {
 ...
}
{code}

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

Reply via email to