Kabaya,
You'll have to learn a bit about defining XML schema. Often just looking at examples will teach you enough to get something working. There are also some books on Web services, which include information on defining WSDL. This is what I had to do, as I'd done no web services work up to a few months ago.
Tony
"Kibaya E." <[EMAIL PROTECTED]> wrote on 05/12/2004 08:02:50:
> Thanks Tony for the advice....unfortunately iam still
> new to all this, could you kindly help further and get
> me on to how i should really do it. It surely seems to
> be the problem.
> kibaya
> --- [EMAIL PROTECTED] wrote:
>
> > Kibaya,
> >
> > My guess is that you have specified the
> > exchangeRequest message as being
> > of type xsd:anyType and Axis can't do anything
> > except assume that it is a
> > simple type. This means that Axis is expecting no
> > child elements of the
> > RequestSecurityToken element. But you have lots of
> > child elements. As soon
> > as the SimpleDeserializer sees a child element, it
> > throws an exception.
> > You'd need to define the RequestSecurityToken in an
> > XML schema, in the
> > <types> section of the WSDL, and refer to that type,
> > instead of
> > xsd:anyType.
> >
> > Tony
> >
> > "Kibaya E." <[EMAIL PROTECTED]> wrote on 02/12/2004
> > 22:25:11:
> >
> > > Hi folks,
> > > Iam still grappling with my problem, not yet
> > solved.
> > > The web service is rightly deployed but on running
> > the
> > > client, i keep on getting simpledeserializer error
> > > thrown by the server! Any ideas where i might have
> > > totally mesed up?
> > > Here is how it looks:
> > > ------------------------------------
> > > ==============
> > > Listen Port: 8081
> > > Target Host: 127.0.0.1
> > > Target Port: 8080
> > > ==== Request ====
> > > POST /axis/services/SecurityTokenService HTTP/1.0
> > > Content-Type: text/xml; charset=utf-8
> > > Accept: application/soap+xml, application/dime,
> > > multipart/related, text/*
> > > User-Agent: Axis/1.1
> > > Host: 127.0.0.1
> > > Cache-Control: no-cache
> > > Pragma: no-cache
> > > SOAPAction: ""
> > > Content-Length: 2611
> > >
> > > <?xml version="1.0" encoding="UTF-8"?>
> > > <soapenv:Envelope
> > >
> >
> xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
> > > xmlns:xsd="http://www.w3.org/2001/XMLSchema"
> > >
> >
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
> > > <soapenv:Body><ns1:RequestSecurityToken
> > > ns1:Context="http://context.context"
> > >
> >
> xmlns:ns1="http://schemas.xmlsoap.org/ws/2004/04/trust"><ns1:
> > >
> >
> TokenType>http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-
> > >
> >
> x509-token-profile-1.0#X509v3</ns1:TokenType><ns2:TestElement
> > >
> >
> xmlns:ns2="http://testElementNs.testElementNs"/><ns1:Lifetime
> > >
> >
> xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-
> > > wssecurity-utility-1.0.xsd"><wsu:Created
> > >
> >
> xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-
> > >
> >
> wssecurity-utility-1.0.xsd">2004-12-03T05:23:33Z</wsu:Created><wsu:Expires
> > >
> >
> xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-
> > >
> >
> wssecurity-utility-1.0.xsd">2004-12-03T05:27:43Z</wsu:Expires></ns1:
> > > Lifetime><ns1:RequestType>http://schemas.xmlsoap.
> > >
> >
> org/ws/2004/04/security/trust/Issue</ns1:RequestType><ns1:
> > > Base><wsse:UsernameToken
> > >
> >
> xmlns:wsse="WSConstants.WSSE_NS_OASIS_2003_06"><wsse:Username
> > >
> >
> xmlns:wsse="WSConstants.WSSE_NS_OASIS_2003_06">elly</wsse:
> > > Username><wsse:Password
> > > Type="PasswordDigest"
> > > xmlns:wsse="WSConstants.
> > >
> >
> WSSE_NS_OASIS_2003_06">N5s2wlHwJazdkBNjey9MMpVgDs4=</wsse:Password><wsse:Nonce
> > > xmlns:wsse="WSConstants.
> > >
> >
> WSSE_NS_OASIS_2003_06">xn41UC/2Q9elnZaQGnp+GQ==</wsse:Nonce><wsu:Created
> > >
> >
> xmlns:wsu="WSConstants.WSSE_NS_OASIS_2003_06">2004-12-03T05:23:
> > >
> >
> 33Z</wsu:Created></wsse:UsernameToken></ns1:Base><ns1:
> > > Supporting><wsse:UsernameToken
> > >
> >
> xmlns:wsse="WSConstants.WSSE_NS_OASIS_2003_06"><wsse:Username
> > >
> >
> xmlns:wsse="WSConstants.WSSE_NS_OASIS_2003_06">martin</wsse:
> > > Username><wsse:Password
> > > Type="PasswordDigest"
> > > xmlns:wsse="WSConstants.
> > >
> >
> WSSE_NS_OASIS_2003_06">rityJY94EkCPN90If83hm1OucmM=</wsse:Password><wsse:Nonce
> > > xmlns:wsse="WSConstants.
> > >
> >
> WSSE_NS_OASIS_2003_06">ad49SOIUshIqz0jmt8bTzQ==</wsse:Nonce><wsu:Created
> > >
> >
> xmlns:wsu="WSConstants.WSSE_NS_OASIS_2003_06">2004-12-03T05:23:
> > >
> >
> 33Z</wsu:Created></wsse:UsernameToken><wsse:UsernameToken
> > >
> >
> xmlns:wsse="WSConstants.WSSE_NS_OASIS_2003_06"><wsse:Username
> > >
> >
> xmlns:wsse="WSConstants.WSSE_NS_OASIS_2003_06">alex</wsse:
> > > Username><wsse:Password
> > > Type="PasswordDigest"
> > > xmlns:wsse="WSConstants.
> > >
> >
> WSSE_NS_OASIS_2003_06">1uhSLU1t1+b+NLNZL1ywo7gnphU=</wsse:Password><wsse:Nonce
> > > xmlns:wsse="WSConstants.
> > >
> >
> WSSE_NS_OASIS_2003_06">bKg5PaAh0mPtc6cQOnwqUg==</wsse:Nonce><wsu:Created
> > >
> >
> xmlns:wsu="WSConstants.WSSE_NS_OASIS_2003_06">2004-12-03T05:23:
> > >
> >
> 33Z</wsu:Created></wsse:UsernameToken></ns1:Supporting></ns1:
> > > RequestSecurityToken>
> > > </soapenv:Body>
> > > </soapenv:Envelope>
> > >
> > > ==== Response ====
> > > HTTP/1.1 500 Internal Server Error
> > > Content-Type: text/xml; charset=utf-8
> > > Date: Fri, 03 Dec 2004 05:23:43 GMT
> > > Server: Apache Coyote/1.0
> > > Connection: close
> > >
> > > <?xml version="1.0" encoding="UTF-8"?>
> > > <soapenv:Envelope
> > >
> >
> xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
> > > xmlns:xsd="http://www.w3.org/2001/XMLSchema"
> > >
> >
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
> > > <soapenv:Body>
> > > <soapenv:Fault>
> > >
> > <faultcode>soapenv:Server.userException</faultcode>
> > > <faultstring>org.xml.sax.SAXException:
> > > SimpleDeserializer encountered a child element,
> > which
> > > is NOT expected, in something it was trying to
> > > deserialize.</faultstring>
> > > <detail/>
> > > </soapenv:Fault>
> > > </soapenv:Body>
> > > </soapenv:Envelope>
> > > ==============
> > >
> > > My wsdl file is here too:
> > > <wsdl:definitions
> > >
> >
> targetNamespace="http://localhost:8080/axis/services/SecurityTokenService">
> > > -
> > > <wsdl:message name="exchangeRequest">
> > > <wsdl:part name="in0" type="xsd:anyType"/>
> > > </wsdl:message>
> > > -
> > > <wsdl:message name="exchangeResponse">
> > > <wsdl:part name="exchangeReturn"
> > type="xsd:anyType"/>
> > > </wsdl:message>
> > > -
> > > <wsdl:portType name="SecurityTokenService">
> > > -
> > > <wsdl:operation name="exchange"
> > parameterOrder="in0">
> > > <wsdl:input message="impl:exchangeRequest"
> > > name="exchangeRequest"/>
> > > <wsdl:output message="impl:exchangeResponse"
> > > name="exchangeResponse"/>
> > > </wsdl:operation>
> > > </wsdl:portType>
> > > -
> > > <wsdl:binding
> > name="SecurityTokenServiceSoapBinding"
> > > type="impl:SecurityTokenService">
> > > <wsdlsoap:binding style="rpc"
> > > transport="http://schemas.xmlsoap.org/soap/http"/>
> > > -
> > > <wsdl:operation name="exchange">
> > > <wsdlsoap:operation soapAction=""/>
> > > -
> > > <wsdl:input name="exchangeRequest">
> > > <wsdlsoap:body
> > >
> >
> encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
> >
> === message truncated ===
>
>
> =====
> KIBAYA ERISANIA
> Msc. Computer Science
> Hunan University,
> Yuelushan, Changsha, Hunan 410082
> P.R China
> Tel:0086 731 8649349
> Mob: 0086 13975103460
> E-Mial: [EMAIL PROTECTED]
> http://www.ekibs.psend.com
>
> Sites of interest
> http://groups.yahoo.com/group/usac/
> http://www.ugandaobserver.com
>
>
>
>
>
>
>
>
>
>
>
> __________________________________
> Do you Yahoo!?
> Read only the mail you want - Yahoo! Mail SpamGuard.
> http://promotions.yahoo.com/new_mail
>
- BASIC AUTHENTICATION doesn't work Ilias Bartolini
- Re: BASIC AUTHENTICATION doesn't work Ilias Bartolini
- Getting Tomcat Realm security working with Axis David Robison
- Re: Getting Tomcat Realm security working w... David Robison
- Re: Getting Tomcat Realm security working w... David Robison
- SimpleDeserializer problem Kibaya E.
- Re: SimpleDeserializer problem tony . q . weddle
- Re: SimpleDeserializer problem Kibaya E.
- tony . q . weddle