Here’s the EJB I want to expose as a web service (Using axis 1.0 with Jboss 3.2.0)

 

  public Document runQuery(DatabaseRequest lDatabaseRequest) {

 

…. Code removed …

           

Document lResults;

 

….  Code removed

 

            return lResults;

  }

 

DatabaseRequest is just a simple class with 4 public member variables… uri, username, password, query.  The WSDL is generated just fine, generating a complex type with databaserequest’s member variables.   I can discover the wsdl fine with a soap client, no problems there. 

 

However when I try to run the service, the request document is constructed properly (watched the logs)…. But I get this error:

org.xml.sax.SAXException: SimpleDeserializer encountered a child element, which is NOT expected, in something it was trying to deserialize.

 

Here’s my web-service.xml file (analogous to wsdd file)

 

<?xml version="1.0" encoding="UTF-8" ?>

  <deployment xmlns="http://xml.apache.org/axis/wsdd/"

            targetNamespace="http://net.jboss.org/database"

            xmlns:database="http://net.jboss.org/database"

            xmlns:java="http://xml.apache.org/axis/wsdd/providers/java">

 

  <service name="database" provider="Handler"           <!-- I’ve also tried  not having in there, same error! à

            <parameter name="handlerClass" value="org.jboss.net.axis.server.EJBProvider" />

            <parameter name="beanJndiName" value="ejb/DatabaseService" />

            <parameter name="homeInterfaceName" value="DatabaseServiceHome" />

            <parameter name="allowedMethods" value="runQuery" />

            <requestFlow name="DatabaseServiceRequest">

                        <handler name="TransactionRequestHandler" type="java:org.jboss.net.axis.server.TransactionRequestHandler" />

            </requestFlow>

            <responseFlow name="DatabaseServiceResponse">

                        <handler name="SerialisationResponseHandler" type="java:org.jboss.net.axis.server.SerialisationResponseHandler" />

                        <handler name="TransactionResponseHandler" type="java:org.jboss.net.axis.server.TransactionResponseHandler" />

            </responseFlow>

  </service>

</deployment>

 

Any ideas how I should expose this service?  It’s supposed to return an XML document with nested elements…..

 

Pete

 

Reply via email to