You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-dev@axis.apache.org by "Thomas Früh (JIRA)" <ax...@ws.apache.org> on 2006/02/09 11:57:57 UTC
[jira] Created: (AXIS-2399) Problem with unbounded elements and
sequence in SimpleAxisServer
Problem with unbounded elements and sequence in SimpleAxisServer
----------------------------------------------------------------
Key: AXIS-2399
URL: http://issues.apache.org/jira/browse/AXIS-2399
Project: Apache Axis
Type: Bug
Components: Serialization/Deserialization
Versions: 1.3
Environment: Java Version 1.4.2_09
SimpleAxisServer
Reporter: Thomas Früh
Priority: Blocker
With the newest version 1.3., I have a problem with following xml schema type:
<?xml version="1.0" encoding="UTF-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified" attributeFormDefault="unqualified">
<xs:complexType name="ucFeedbackRequestType">
<xs:sequence>
<xs:element name="ucLabel" type="xs:string"/>
<xs:element name="possibleAnswers">
<xs:complexType>
<xs:sequence>
<xs:element name="Answer" maxOccurs="unbounded">
<xs:complexType>
<xs:sequence>
<xs:element name="code" type="xs:string"/>
<xs:element name="text" type="xs:string"/>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="defaultCode" type="xs:string"/>
<xs:element name="timeOut" type="xs:unsignedInt"/>
</xs:sequence>
</xs:complexType>
</xs:schema>
In our Java Application I use the SimpleAxisServer to receive some soap messages from a client.
If the SimpleAxisServer receive a SOAP Message with the upper structure, then I get the following error in the client:
<?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>
<ns1:stackTrace xmlns:ns1="http://xml.apache.org/axis/">org.xml.sax.SAXException: SimpleDeserializer encountered a child element, which is NOT expected, in something it was trying to deserialize.
org.apache.axis.encoding.ser.SimpleDeserializer.onStartChild(SimpleDeserializer.java:145)
org.apache.axis.encoding.DeserializationContext.startElement(DeserializationContext.java:1035)
org.apache.axis.message.SAX2EventRecorder.replay(SAX2EventRecorder.java:165)
org.apache.axis.message.MessageElement.publishToHandler(MessageElement.java:1141)
org.apache.axis.message.RPCElement.deserialize(RPCElement.java:236)
org.apache.axis.message.RPCElement.getParams(RPCElement.java:384)
org.apache.axis.providers.java.RPCProvider.processMessage(RPCProvider.java:81)
org.apache.axis.providers.java.JavaProvider.invoke(JavaProvider.java:323)
org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)
org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)
org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
org.apache.axis.handlers.soap.SOAPService.invoke(SOAPService.java:453)
org.apache.axis.server.AxisServer.invoke(AxisServer.java:281)
org.apache.axis.transport.http.SimpleAxisWorker.execute(SimpleAxisWorker.java:428)
org.apache.axis.transport.http.SimpleAxisWorker.run(SimpleAxisWorker.java:155)
java.lang.Thread.run(Unknown Source)
</ns1:stackTrace>
<ns2:hostname xmlns:ns2="http://xml.apache.org/axis/">CHZRHD0CH0152</ns2:hostname>
</detail>
</soapenv:Fault>
</soapenv:Body>
</soapenv:Envelope>
If the SimpleAxisServer receive a soap message with an empty <xs:element name="possibleAnswers"> tag then there is no error.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
[jira] Updated: (AXIS-2399) Problem with unbounded elements and
sequence in SimpleAxisServer
Posted by "Thomas Früh (JIRA)" <ax...@ws.apache.org>.
[ http://issues.apache.org/jira/browse/AXIS-2399?page=all ]
Thomas Früh updated AXIS-2399:
------------------------------
Attachment: ExampleCall.xml
> Problem with unbounded elements and sequence in SimpleAxisServer
> ----------------------------------------------------------------
>
> Key: AXIS-2399
> URL: http://issues.apache.org/jira/browse/AXIS-2399
> Project: Apache Axis
> Type: Bug
> Components: Serialization/Deserialization
> Versions: 1.3
> Environment: Java Version 1.4.2_09
> SimpleAxisServer
> Reporter: Thomas Früh
> Priority: Blocker
> Attachments: Example.xsd, ExampleCall.xml
>
> With the newest version 1.3., I have a problem with following xml schema type:
> <?xml version="1.0" encoding="UTF-8"?>
> <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified" attributeFormDefault="unqualified">
> <xs:complexType name="ucFeedbackRequestType">
> <xs:sequence>
> <xs:element name="ucLabel" type="xs:string"/>
> <xs:element name="possibleAnswers">
> <xs:complexType>
> <xs:sequence>
> <xs:element name="Answer" maxOccurs="unbounded">
> <xs:complexType>
> <xs:sequence>
> <xs:element name="code" type="xs:string"/>
> <xs:element name="text" type="xs:string"/>
> </xs:sequence>
> </xs:complexType>
> </xs:element>
> </xs:sequence>
> </xs:complexType>
> </xs:element>
> <xs:element name="defaultCode" type="xs:string"/>
> <xs:element name="timeOut" type="xs:unsignedInt"/>
> </xs:sequence>
> </xs:complexType>
> </xs:schema>
> In our Java Application I use the SimpleAxisServer to receive some soap messages from a client.
> If the SimpleAxisServer receive a SOAP Message with the upper structure, then I get the following error in the client:
> <?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>
> <ns1:stackTrace xmlns:ns1="http://xml.apache.org/axis/">org.xml.sax.SAXException: SimpleDeserializer encountered a child element, which is NOT expected, in something it was trying to deserialize.
> org.apache.axis.encoding.ser.SimpleDeserializer.onStartChild(SimpleDeserializer.java:145)
> org.apache.axis.encoding.DeserializationContext.startElement(DeserializationContext.java:1035)
> org.apache.axis.message.SAX2EventRecorder.replay(SAX2EventRecorder.java:165)
> org.apache.axis.message.MessageElement.publishToHandler(MessageElement.java:1141)
> org.apache.axis.message.RPCElement.deserialize(RPCElement.java:236)
> org.apache.axis.message.RPCElement.getParams(RPCElement.java:384)
> org.apache.axis.providers.java.RPCProvider.processMessage(RPCProvider.java:81)
> org.apache.axis.providers.java.JavaProvider.invoke(JavaProvider.java:323)
> org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)
> org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)
> org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
> org.apache.axis.handlers.soap.SOAPService.invoke(SOAPService.java:453)
> org.apache.axis.server.AxisServer.invoke(AxisServer.java:281)
> org.apache.axis.transport.http.SimpleAxisWorker.execute(SimpleAxisWorker.java:428)
> org.apache.axis.transport.http.SimpleAxisWorker.run(SimpleAxisWorker.java:155)
> java.lang.Thread.run(Unknown Source)
> </ns1:stackTrace>
> <ns2:hostname xmlns:ns2="http://xml.apache.org/axis/">CHZRHD0CH0152</ns2:hostname>
> </detail>
> </soapenv:Fault>
> </soapenv:Body>
> </soapenv:Envelope>
>
> If the SimpleAxisServer receive a soap message with an empty <xs:element name="possibleAnswers"> tag then there is no error.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
[jira] Commented: (AXIS-2399) Problem with unbounded elements and
sequence in SimpleAxisServer
Posted by "Thomas Früh (JIRA)" <ax...@ws.apache.org>.
[ http://issues.apache.org/jira/browse/AXIS-2399?page=comments#action_12367181 ]
Thomas Früh commented on AXIS-2399:
-----------------------------------
I used the TCPMon and generate/attach an XML file (ExampleCall.xml), this is a copy of the soap call that don't work.
I'm shure that the TypeMappings are defined in good way. I can't see anything wrong in the soap call.
By the way: Bjorn could you say me which more complete server do you opine.
> Problem with unbounded elements and sequence in SimpleAxisServer
> ----------------------------------------------------------------
>
> Key: AXIS-2399
> URL: http://issues.apache.org/jira/browse/AXIS-2399
> Project: Apache Axis
> Type: Bug
> Components: Serialization/Deserialization
> Versions: 1.3
> Environment: Java Version 1.4.2_09
> SimpleAxisServer
> Reporter: Thomas Früh
> Priority: Blocker
> Attachments: Example.xsd, ExampleCall.xml
>
> With the newest version 1.3., I have a problem with following xml schema type:
> <?xml version="1.0" encoding="UTF-8"?>
> <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified" attributeFormDefault="unqualified">
> <xs:complexType name="ucFeedbackRequestType">
> <xs:sequence>
> <xs:element name="ucLabel" type="xs:string"/>
> <xs:element name="possibleAnswers">
> <xs:complexType>
> <xs:sequence>
> <xs:element name="Answer" maxOccurs="unbounded">
> <xs:complexType>
> <xs:sequence>
> <xs:element name="code" type="xs:string"/>
> <xs:element name="text" type="xs:string"/>
> </xs:sequence>
> </xs:complexType>
> </xs:element>
> </xs:sequence>
> </xs:complexType>
> </xs:element>
> <xs:element name="defaultCode" type="xs:string"/>
> <xs:element name="timeOut" type="xs:unsignedInt"/>
> </xs:sequence>
> </xs:complexType>
> </xs:schema>
> In our Java Application I use the SimpleAxisServer to receive some soap messages from a client.
> If the SimpleAxisServer receive a SOAP Message with the upper structure, then I get the following error in the client:
> <?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>
> <ns1:stackTrace xmlns:ns1="http://xml.apache.org/axis/">org.xml.sax.SAXException: SimpleDeserializer encountered a child element, which is NOT expected, in something it was trying to deserialize.
> org.apache.axis.encoding.ser.SimpleDeserializer.onStartChild(SimpleDeserializer.java:145)
> org.apache.axis.encoding.DeserializationContext.startElement(DeserializationContext.java:1035)
> org.apache.axis.message.SAX2EventRecorder.replay(SAX2EventRecorder.java:165)
> org.apache.axis.message.MessageElement.publishToHandler(MessageElement.java:1141)
> org.apache.axis.message.RPCElement.deserialize(RPCElement.java:236)
> org.apache.axis.message.RPCElement.getParams(RPCElement.java:384)
> org.apache.axis.providers.java.RPCProvider.processMessage(RPCProvider.java:81)
> org.apache.axis.providers.java.JavaProvider.invoke(JavaProvider.java:323)
> org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)
> org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)
> org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
> org.apache.axis.handlers.soap.SOAPService.invoke(SOAPService.java:453)
> org.apache.axis.server.AxisServer.invoke(AxisServer.java:281)
> org.apache.axis.transport.http.SimpleAxisWorker.execute(SimpleAxisWorker.java:428)
> org.apache.axis.transport.http.SimpleAxisWorker.run(SimpleAxisWorker.java:155)
> java.lang.Thread.run(Unknown Source)
> </ns1:stackTrace>
> <ns2:hostname xmlns:ns2="http://xml.apache.org/axis/">CHZRHD0CH0152</ns2:hostname>
> </detail>
> </soapenv:Fault>
> </soapenv:Body>
> </soapenv:Envelope>
>
> If the SimpleAxisServer receive a soap message with an empty <xs:element name="possibleAnswers"> tag then there is no error.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
[jira] Updated: (AXIS-2399) Problem with unbounded elements and
sequence in SimpleAxisServer
Posted by "Thomas Früh (JIRA)" <ax...@ws.apache.org>.
[ http://issues.apache.org/jira/browse/AXIS-2399?page=all ]
Thomas Früh updated AXIS-2399:
------------------------------
Attachment: Example.xsd
Example of the problematic schema.
> Problem with unbounded elements and sequence in SimpleAxisServer
> ----------------------------------------------------------------
>
> Key: AXIS-2399
> URL: http://issues.apache.org/jira/browse/AXIS-2399
> Project: Apache Axis
> Type: Bug
> Components: Serialization/Deserialization
> Versions: 1.3
> Environment: Java Version 1.4.2_09
> SimpleAxisServer
> Reporter: Thomas Früh
> Priority: Blocker
> Attachments: Example.xsd
>
> With the newest version 1.3., I have a problem with following xml schema type:
> <?xml version="1.0" encoding="UTF-8"?>
> <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified" attributeFormDefault="unqualified">
> <xs:complexType name="ucFeedbackRequestType">
> <xs:sequence>
> <xs:element name="ucLabel" type="xs:string"/>
> <xs:element name="possibleAnswers">
> <xs:complexType>
> <xs:sequence>
> <xs:element name="Answer" maxOccurs="unbounded">
> <xs:complexType>
> <xs:sequence>
> <xs:element name="code" type="xs:string"/>
> <xs:element name="text" type="xs:string"/>
> </xs:sequence>
> </xs:complexType>
> </xs:element>
> </xs:sequence>
> </xs:complexType>
> </xs:element>
> <xs:element name="defaultCode" type="xs:string"/>
> <xs:element name="timeOut" type="xs:unsignedInt"/>
> </xs:sequence>
> </xs:complexType>
> </xs:schema>
> In our Java Application I use the SimpleAxisServer to receive some soap messages from a client.
> If the SimpleAxisServer receive a SOAP Message with the upper structure, then I get the following error in the client:
> <?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>
> <ns1:stackTrace xmlns:ns1="http://xml.apache.org/axis/">org.xml.sax.SAXException: SimpleDeserializer encountered a child element, which is NOT expected, in something it was trying to deserialize.
> org.apache.axis.encoding.ser.SimpleDeserializer.onStartChild(SimpleDeserializer.java:145)
> org.apache.axis.encoding.DeserializationContext.startElement(DeserializationContext.java:1035)
> org.apache.axis.message.SAX2EventRecorder.replay(SAX2EventRecorder.java:165)
> org.apache.axis.message.MessageElement.publishToHandler(MessageElement.java:1141)
> org.apache.axis.message.RPCElement.deserialize(RPCElement.java:236)
> org.apache.axis.message.RPCElement.getParams(RPCElement.java:384)
> org.apache.axis.providers.java.RPCProvider.processMessage(RPCProvider.java:81)
> org.apache.axis.providers.java.JavaProvider.invoke(JavaProvider.java:323)
> org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)
> org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)
> org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
> org.apache.axis.handlers.soap.SOAPService.invoke(SOAPService.java:453)
> org.apache.axis.server.AxisServer.invoke(AxisServer.java:281)
> org.apache.axis.transport.http.SimpleAxisWorker.execute(SimpleAxisWorker.java:428)
> org.apache.axis.transport.http.SimpleAxisWorker.run(SimpleAxisWorker.java:155)
> java.lang.Thread.run(Unknown Source)
> </ns1:stackTrace>
> <ns2:hostname xmlns:ns2="http://xml.apache.org/axis/">CHZRHD0CH0152</ns2:hostname>
> </detail>
> </soapenv:Fault>
> </soapenv:Body>
> </soapenv:Envelope>
>
> If the SimpleAxisServer receive a soap message with an empty <xs:element name="possibleAnswers"> tag then there is no error.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
[jira] Commented: (AXIS-2399) Problem with unbounded elements and
sequence in SimpleAxisServer
Posted by "Bjorn Townsend (JIRA)" <ax...@ws.apache.org>.
[ http://issues.apache.org/jira/browse/AXIS-2399?page=comments#action_12366694 ]
Bjorn Townsend commented on AXIS-2399:
--------------------------------------
Looking at the source code for the exception,
/**
* There should not be nested elements, so thow and exception if this occurs.
*/
public SOAPHandler onStartChild(String namespace,
String localName,
String prefix,
Attributes attributes,
DeserializationContext context)
throws SAXException
{
throw new SAXException(
Messages.getMessage("cantHandle00", "SimpleDeserializer"));
}
it seems pretty clear that the SimpleDeserializer is not intended to handle nested elements. It looks like a different deserializer needs to be used, but I think you may be going beyond SimpleAxisServer's intended capabilities. From the Simple Axis Server class javadoc notes:
"This is a simple implementation of an HTTP server for processing SOAP requests via Apache's xml-axis. This is not intended for production use. Its intended uses are for demos, debugging, and performance profiling."
(http://ws.apache.org/axis/java/apiDocs/org/apache/axis/transport/http/SimpleAxisServer.html)
And it looks to me like SimpleAxisServer is designed to use only the SimpleDeserializer. I would say you need to use a more complete server for this application.
> Problem with unbounded elements and sequence in SimpleAxisServer
> ----------------------------------------------------------------
>
> Key: AXIS-2399
> URL: http://issues.apache.org/jira/browse/AXIS-2399
> Project: Apache Axis
> Type: Bug
> Components: Serialization/Deserialization
> Versions: 1.3
> Environment: Java Version 1.4.2_09
> SimpleAxisServer
> Reporter: Thomas Früh
> Priority: Blocker
> Attachments: Example.xsd
>
> With the newest version 1.3., I have a problem with following xml schema type:
> <?xml version="1.0" encoding="UTF-8"?>
> <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified" attributeFormDefault="unqualified">
> <xs:complexType name="ucFeedbackRequestType">
> <xs:sequence>
> <xs:element name="ucLabel" type="xs:string"/>
> <xs:element name="possibleAnswers">
> <xs:complexType>
> <xs:sequence>
> <xs:element name="Answer" maxOccurs="unbounded">
> <xs:complexType>
> <xs:sequence>
> <xs:element name="code" type="xs:string"/>
> <xs:element name="text" type="xs:string"/>
> </xs:sequence>
> </xs:complexType>
> </xs:element>
> </xs:sequence>
> </xs:complexType>
> </xs:element>
> <xs:element name="defaultCode" type="xs:string"/>
> <xs:element name="timeOut" type="xs:unsignedInt"/>
> </xs:sequence>
> </xs:complexType>
> </xs:schema>
> In our Java Application I use the SimpleAxisServer to receive some soap messages from a client.
> If the SimpleAxisServer receive a SOAP Message with the upper structure, then I get the following error in the client:
> <?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>
> <ns1:stackTrace xmlns:ns1="http://xml.apache.org/axis/">org.xml.sax.SAXException: SimpleDeserializer encountered a child element, which is NOT expected, in something it was trying to deserialize.
> org.apache.axis.encoding.ser.SimpleDeserializer.onStartChild(SimpleDeserializer.java:145)
> org.apache.axis.encoding.DeserializationContext.startElement(DeserializationContext.java:1035)
> org.apache.axis.message.SAX2EventRecorder.replay(SAX2EventRecorder.java:165)
> org.apache.axis.message.MessageElement.publishToHandler(MessageElement.java:1141)
> org.apache.axis.message.RPCElement.deserialize(RPCElement.java:236)
> org.apache.axis.message.RPCElement.getParams(RPCElement.java:384)
> org.apache.axis.providers.java.RPCProvider.processMessage(RPCProvider.java:81)
> org.apache.axis.providers.java.JavaProvider.invoke(JavaProvider.java:323)
> org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)
> org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)
> org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
> org.apache.axis.handlers.soap.SOAPService.invoke(SOAPService.java:453)
> org.apache.axis.server.AxisServer.invoke(AxisServer.java:281)
> org.apache.axis.transport.http.SimpleAxisWorker.execute(SimpleAxisWorker.java:428)
> org.apache.axis.transport.http.SimpleAxisWorker.run(SimpleAxisWorker.java:155)
> java.lang.Thread.run(Unknown Source)
> </ns1:stackTrace>
> <ns2:hostname xmlns:ns2="http://xml.apache.org/axis/">CHZRHD0CH0152</ns2:hostname>
> </detail>
> </soapenv:Fault>
> </soapenv:Body>
> </soapenv:Envelope>
>
> If the SimpleAxisServer receive a soap message with an empty <xs:element name="possibleAnswers"> tag then there is no error.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
[jira] Commented: (AXIS-2399) Problem with unbounded elements and
sequence in SimpleAxisServer
Posted by "Tom Jordahl (JIRA)" <ax...@ws.apache.org>.
[ http://issues.apache.org/jira/browse/AXIS-2399?page=comments#action_12366804 ]
Tom Jordahl commented on AXIS-2399:
-----------------------------------
SimpleAxisServer should be fine for the use that Thomas is using it for. The error indicates that there are missing type mappings for the XML that the service is receiving. The server is expect something like <mything>foo</mything> and getting something like <mything><child>foo</child></mything>.
Looking at the SOAP request and comparing that to the Schema, then making sure you have TypeMappings for each of the QName that are complexTypes is a good way to debug this. Use TCPMon (part of Axis).
> Problem with unbounded elements and sequence in SimpleAxisServer
> ----------------------------------------------------------------
>
> Key: AXIS-2399
> URL: http://issues.apache.org/jira/browse/AXIS-2399
> Project: Apache Axis
> Type: Bug
> Components: Serialization/Deserialization
> Versions: 1.3
> Environment: Java Version 1.4.2_09
> SimpleAxisServer
> Reporter: Thomas Früh
> Priority: Blocker
> Attachments: Example.xsd
>
> With the newest version 1.3., I have a problem with following xml schema type:
> <?xml version="1.0" encoding="UTF-8"?>
> <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified" attributeFormDefault="unqualified">
> <xs:complexType name="ucFeedbackRequestType">
> <xs:sequence>
> <xs:element name="ucLabel" type="xs:string"/>
> <xs:element name="possibleAnswers">
> <xs:complexType>
> <xs:sequence>
> <xs:element name="Answer" maxOccurs="unbounded">
> <xs:complexType>
> <xs:sequence>
> <xs:element name="code" type="xs:string"/>
> <xs:element name="text" type="xs:string"/>
> </xs:sequence>
> </xs:complexType>
> </xs:element>
> </xs:sequence>
> </xs:complexType>
> </xs:element>
> <xs:element name="defaultCode" type="xs:string"/>
> <xs:element name="timeOut" type="xs:unsignedInt"/>
> </xs:sequence>
> </xs:complexType>
> </xs:schema>
> In our Java Application I use the SimpleAxisServer to receive some soap messages from a client.
> If the SimpleAxisServer receive a SOAP Message with the upper structure, then I get the following error in the client:
> <?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>
> <ns1:stackTrace xmlns:ns1="http://xml.apache.org/axis/">org.xml.sax.SAXException: SimpleDeserializer encountered a child element, which is NOT expected, in something it was trying to deserialize.
> org.apache.axis.encoding.ser.SimpleDeserializer.onStartChild(SimpleDeserializer.java:145)
> org.apache.axis.encoding.DeserializationContext.startElement(DeserializationContext.java:1035)
> org.apache.axis.message.SAX2EventRecorder.replay(SAX2EventRecorder.java:165)
> org.apache.axis.message.MessageElement.publishToHandler(MessageElement.java:1141)
> org.apache.axis.message.RPCElement.deserialize(RPCElement.java:236)
> org.apache.axis.message.RPCElement.getParams(RPCElement.java:384)
> org.apache.axis.providers.java.RPCProvider.processMessage(RPCProvider.java:81)
> org.apache.axis.providers.java.JavaProvider.invoke(JavaProvider.java:323)
> org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)
> org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)
> org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
> org.apache.axis.handlers.soap.SOAPService.invoke(SOAPService.java:453)
> org.apache.axis.server.AxisServer.invoke(AxisServer.java:281)
> org.apache.axis.transport.http.SimpleAxisWorker.execute(SimpleAxisWorker.java:428)
> org.apache.axis.transport.http.SimpleAxisWorker.run(SimpleAxisWorker.java:155)
> java.lang.Thread.run(Unknown Source)
> </ns1:stackTrace>
> <ns2:hostname xmlns:ns2="http://xml.apache.org/axis/">CHZRHD0CH0152</ns2:hostname>
> </detail>
> </soapenv:Fault>
> </soapenv:Body>
> </soapenv:Envelope>
>
> If the SimpleAxisServer receive a soap message with an empty <xs:element name="possibleAnswers"> tag then there is no error.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira