Hallo all, We have quite a similar problem like the one Bob reported back in February:
We try to use the wsgen ant task to process a WSDL document in order to create a client. The WSDL document defines headers (including wsse headers like in Bob's case). The resulting code does not only look as ugly as Bob described, it also *does not work*! We are using the XmlBeans binding. I somehow doubt that nobody out there uses wsse with the XmlBeans binding, so if someone has any clue, we would appreciate any advice. Right now this is a real show stopper... Regards, Christian Seiler BTW: Would opening a JIRA issue help in any way? We have opened a JIRA issue (for a different but remotely related problem [644]) in the past and got no response at all >I'm using the wsgen ant task to process our wsdl. When I was using Axis, the >web service call had logical arguments. With Xfire, it's generating a large >number of redundant arguments in the method signature to the web service call >that have no obvious meaning to me. Maybe an example would help explain. > >Here is the wsdl: > ><?xml version="1.0" encoding="UTF-8"?> ><definitions xmlns="http://schemas.xmlsoap.org/wsdl/" >xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" >xmlns:xs="http://www.w3.org/2001/XMLSchema" >xmlns:xsd1="http://www.opentravel.org/OTA/2002/11" >xmlns:tns="https://webservices.sabre.com/websvc" >xmlns:eb="http://www.ebxml.org/namespaces/messageHeader" >xmlns:wsse="http://schemas.xmlsoap.org/ws/2002/12/secext" >targetNamespace="https://webservices.sabre.com/websvc"> > <types> > <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema"> > <xsd:import namespace="http://www.opentravel.org/OTA/2002/11" >schemaLocation="SessionCreateRQRS.xsd"/> > <xsd:import namespace="http://www.ebxml.org/namespaces/messageHeader" >schemaLocation="msg-header-2_0.xsd"/> > <xsd:import namespace="http://www.w3.org/2000/09/xmldsig#" >schemaLocation="xmldsig-core-schema.xsd"/> > <xsd:import namespace="http://www.w3.org/1999/xlink" >schemaLocation="xlink.xsd"/> > <xsd:import namespace="http://schemas.xmlsoap.org/soap/envelope/" >schemaLocation="envelope.xsd"/> > <xsd:import namespace="http://www.w3.org/XML/1998/namespace" >schemaLocation="xml.xsd"/> > <xsd:import namespace="http://schemas.xmlsoap.org/ws/2002/12/secext" >schemaLocation="wsse.xsd"/> > </xsd:schema> > </types> > <message name="GetSessionCreateInput"> > <part name="header" element="eb:MessageHeader"/> > <part name="header2" element="wsse:Security"/> > <part name="body" element="xsd1:SessionCreateRQ"/> > </message> > <message name="GetSessionCreateOutput"> > <part name="header" element="eb:MessageHeader"/> > <part name="header2" element="wsse:Security"/> > <part name="body" element="xsd1:SessionCreateRS"/> > </message> > <portType name="SessionCreatePortType"> > <operation name="SessionCreateRQ"> > <input message="tns:GetSessionCreateInput"/> > <output message="tns:GetSessionCreateOutput"/> > </operation> > </portType> > <binding name="SessionCreateSoapBinding" type="tns:SessionCreatePortType"> > <soap:binding style="document" >transport="http://schemas.xmlsoap.org/soap/http"/> > <operation name="SessionCreateRQ"> > <soap:operation soapAction="OTA"/> > <input> > <soap:header message="tns:GetSessionCreateInput" part="header" >use="literal"/> > <soap:header message="tns:GetSessionCreateInput" part="header2" >use="literal"/> > <soap:body parts="body" use="literal"/> > </input> > <output> > <soap:header message="tns:GetSessionCreateOutput" part="header" >use="literal"/> > <soap:header message="tns:GetSessionCreateOutput" part="header2" >use="literal"/> > <soap:body parts="body" use="literal"/> > </output> > </operation> > </binding> > <service name="SessionCreateRQService"> > <port name="SessionCreatePortType" binding="tns:SessionCreateSoapBinding"> > <soap:address location="https://webservices.sabre.com/websvc"/> > </port> > </service> ></definitions> > >Here is what Axis generates. You make the call doing something like this: > > response = sessionCreateRQ(messageHeader, security, request); > >------------------------------------------ >/** > * SessionCreatePortType.java > * > * This file was auto-generated from WSDL > * by the Apache Axis WSDL2Java emitter. > */ > >package com.sabre.webservices.websvc; > >public interface SessionCreatePortType extends java.rmi.Remote { > public org.opentravel.www.OTA._2002._11._SessionCreateRS >sessionCreateRQ( >org.ebxml.www.namespaces.messageHeader.holders._MessageHeaderHolder >header, org.xmlsoap.schemas.ws._2002._12.secext.holders._SecurityHolder >header2, >org.opentravel.www.OTA._2002._11._SessionCreateRQ body) throws >java.rmi.RemoteException; >------------------------------------------- > >Here is what Xfire wsgen generates. It has 10 parameters. I'm not sure what >it's expecting me to pass to it since most of them are redundant. > >------------------------------------------- > >package com.getthere.sabreclient; > >import javax.jws.WebMethod; >import javax.jws.WebParam; >import javax.jws.WebParam.Mode; >import javax.jws.WebResult; >import javax.jws.WebService; >import javax.jws.soap.SOAPBinding; >import javax.jws.soap.SOAPBinding.ParameterStyle; >import javax.jws.soap.SOAPBinding.Style; >import javax.jws.soap.SOAPBinding.Use; >import javax.xml.ws.Holder; >import com.getthere.sabreclient.SessionCreatePortType; > > <at> WebService(name = "SessionCreatePortType", targetNamespace = >"https://webservices.sabre.com/websvc") > <at> SOAPBinding(style = Style.DOCUMENT, use = Use.LITERAL, parameterStyle = >ParameterStyle.BARE) >public interface SessionCreatePortType { > > <at> WebMethod(operationName = "SessionCreateRQ", action = "OTA") > <at> WebResult(name = "MessageHeader", targetNamespace = >"http://www.ebxml.org/namespaces/messageHeader") > public org.ebxml.namespaces.messageheader.MessageHeader sessionCreateRQ( > <at> WebParam(name = "MessageHeader", targetNamespace = >"http://www.ebxml.org/namespaces/messageHeader") > org.ebxml.namespaces.messageheader.MessageHeader MessageHeader, > <at> WebParam(name = "Security", targetNamespace = >"http://schemas.xmlsoap.org/ws/2002/12/secext") > org.xmlsoap.schemas.ws._2002._12.secext.Security Security, > <at> WebParam(name = "SessionCreateRQ", targetNamespace = >"http://www.opentravel.org/OTA/2002/11") > org.opentravel.ota._2002._11.SessionCreateRQ SessionCreateRQ, > <at> WebParam(name = "MessageHeader", targetNamespace = >"http://www.ebxml.org/namespaces/messageHeader", header = true) > org.ebxml.namespaces.messageheader.MessageHeader MessageHeader2, > <at> WebParam(name = "Security", targetNamespace = >"http://schemas.xmlsoap.org/ws/2002/12/secext", header = true) > org.xmlsoap.schemas.ws._2002._12.secext.Security Security2, > <at> WebParam(name = "Security", targetNamespace = >"http://schemas.xmlsoap.org/ws/2002/12/secext", mode = Mode.OUT) > Holder<org.xmlsoap.schemas.ws._2002._12.secext.Security> Security3, > <at> WebParam(name = "SessionCreateRS", targetNamespace = >"http://www.opentravel.org/OTA/2002/11", mode = Mode.OUT) > Holder<org.opentravel.ota._2002._11.SessionCreateRS> SessionCreateRS, > <at> WebParam(name = "MessageHeader", targetNamespace = >"http://www.ebxml.org/namespaces/messageHeader", mode = Mode.OUT, header = >true) > Holder<org.ebxml.namespaces.messageheader.MessageHeader> > MessageHeader3, > <at> WebParam(name = "Security", targetNamespace = >"http://schemas.xmlsoap.org/ws/2002/12/secext", mode = Mode.OUT, header = true) > Holder<org.xmlsoap.schemas.ws._2002._12.secext.Security> Security4); > >} >----------------------- > >Thanks for any advice you can provide. > >--------------------------------------------------------------------- >To unsubscribe from this list please visit: > > http://xircles.codehaus.org/manage_email -- InteRes GmbH - Dr. Christian Seiler Rheinstrasse 44-46 64283 Darmstadt fon: +49 6151 307 40 18 fax: -11 www.interes.com [EMAIL PROTECTED] Geschäftsführer: Volker Herrmann und Thomas Kreß Registergericht: Amtsgericht Darmstadt Registernummer: HRB 6831/Darmstadt Steuernummer: DE 189 632 313 --------------------------------------------------------------------- To unsubscribe from this list please visit: http://xircles.codehaus.org/manage_email
