You are viewing a plain text version of this content. The canonical link for it is here.
Posted to muse-user@ws.apache.org by "Assaf ." <as...@primagrid.com> on 2006/04/20 19:23:24 UTC

problem invoking service

Hi,

I have a problem while invoking a test muse service I wrote.
(Find attached the WSDL file of the service).
As you can see in the WSDL file, the service exposes an operation 'create' which has one input argument of type string.
As I am writing a client which is supposed to invoke the service, I am generating a SOAP request and sending it to the server.
I looked through the following article that instructs how to build a SOAP message for literal wrapped services.
AFAIK the SOAP message I'm sending to the service is supposed to be correct.
Following is the SOAP message I'm sending to the service and the log from the tomcat in DEBUG logging level.

SOAP:
Sending request: 

<Envelope xmlns="http://schemas.xmlsoap.org/soap/envelope/" xmlns:m="http://www.primagrid.com/test/one/testservice" xmlns:add="http://schemas.xmlsoap.org/ws/2004/08/addressing" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
  <Header>
    <add:To>http://localhost:8080/muse/services/ServicesAdmin</add:To>
    <add:Action>http://www.primagrid.com/test/one/testservice/ServicesAdminPortType/Create</add:Action>
    <m:ResourceIdentifier>1</m:ResourceIdentifier>
  </Header>
  <Body>
    <m:create>
      <resourcetypename>1</resourcetypename>
    </m:create>
  </Body>
</Envelope>
 
LOG:
--> 04-20-06 18:35:46 DEBUG [http-8080-2] ResourceHandler: Received request.
--> 04-20-06 18:35:46 DEBUG [http-8080-2] ResourceHandler: Received SOAP request: 
<?xml version="1.0" encoding="UTF-8"?><!-- edited with XMLSpy v2006 sp2 U (http://www.altova.com) by vahal (AnonymousComp) --><Envelope xmlns="http://schemas.xmlsoap.org/soap/envelope/" xmlns:m="http://www.primagrid.com/test/one/testservice" xmlns:add="http://schemas.xmlsoap.org/ws/2004/08/addressing" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
            <Header>
                        <add:To>http://localhost:8080/muse/services/ServicesAdmin</add:To>
                        <add:Action>http://www.primagrid.com/test/one/testservice/ServicesAdminPortType/Create</add:Action>
                        <m:ResourceIdentifier>1</m:ResourceIdentifier>
            </Header>
            <Body>
                        <m:create>
                                    <resourcetypename type="xsd:string"/>
                        </m:create>
            </Body>
</Envelope>
--> 04-20-06 18:35:46 DEBUG [http-8080-2] ProjectResourceBundle: org.apache.ws.resource.i18n.resource::handleGetObject(GET_ACTION_FROM_ADDR_HDR)
--> 04-20-06 18:35:46 DEBUG [http-8080-2] AbstractResourceContext: Retrieving the Action from the Addressing Headers.  Action is: http://www.primagrid.com/test/one/testservice/ServicesAdminPortType/Create
--> 04-20-06 18:35:46 DEBUG [http-8080-2] ProjectResourceBundle: org.apache.ws.resource.i18n.resource::handleGetObject(JNDI_HOME_LOCATION)
--> 04-20-06 18:35:46 DEBUG [http-8080-2] AbstractResourceContext: The JNDI home location is: wsrf/services/ServicesAdmin/home
--> 04-20-06 18:35:46 DEBUG [http-8080-2] ProjectResourceBundle: org.apache.ws.resource.i18n.resource::handleGetObject(RETRIEVED_SERVICE_CLASSNAME)
--> 04-20-06 18:35:46 DEBUG [http-8080-2] ResourceHandler: Retrieved service classname: com.primagrid.test.one.testservice.ServicesAdminService from resource home.
--> 04-20-06 18:35:46 DEBUG [http-8080-2] ProjectResourceBundle: org.apache.ws.resource.i18n.resource::handleGetObject(CREATING_INSTANCE_OF_SERVICE)
--> 04-20-06 18:35:46 DEBUG [http-8080-2] ResourceHandler: Creating an instance of service class: class com.primagrid.test.one.testservice.ServicesAdminService
--> 04-20-06 18:35:48 DEBUG [http-8080-2] ProjectResourceBundle: org.apache.ws.util.i18n.resource::handleGetObject(CONVRT_QNAME_TO_NAME)
--> 04-20-06 18:35:48 DEBUG [http-8080-2] NameUtils: Converting QName to Name.  QName: {http://www.primagrid.com/test/one/testservice}ResourceIdentifier
--> 04-20-06 18:35:48 DEBUG [http-8080-2] ProjectResourceBundle: org.apache.ws.util.i18n.resource::handleGetObject(CREATING_NAME)
--> 04-20-06 18:35:48 DEBUG [http-8080-2] NameUtils: Creating a Name from localpart: ResourceIdentifier prefix:  uri: http://www.primagrid.com/test/one/testservice
--> 04-20-06 18:35:48 DEBUG [http-8080-2] ProjectResourceBundle: org.apache.ws.resource.i18n.resource::handleGetObject(FINDING_RESOURCE_WITH_KEY)
--> 04-20-06 18:35:48 DEBUG [http-8080-2] AbstractResourceHome: Finding resource with key 1 ...
-> 04-20-06 18:35:48 DEBUG [http-8080-2] ProjectResourceBundle: org.apache.ws.resource.i18n.resource::handleGetObject(GETTING_RESOURCE_WITH_ID)
--> 04-20-06 18:35:48 DEBUG [http-8080-2] AbstractResourceHome: Attempting to lookup resource with identifier 1 from com.primagrid.test.one.testservice.ServicesAdminHome ...
--> 04-20-06 18:35:48 DEBUG [http-8080-2] ProjectResourceBundle: org.apache.ws.resource.i18n.resource::handleGetObject(DERIVE_SERVICE_NAME_FROM_REQ)
--> 04-20-06 18:35:48 DEBUG [http-8080-2] ResourceHandler: Deriving the service method name from the request body element name (create@http://www.primagrid.com/test/one/testservice)...
--> 04-20-06 18:35:48 DEBUG [http-8080-2] ResourceHandler: Based on the request, looking for method named: create in service com.primagrid.test.one.testservice.ServicesAdminService with a single param of type: org.apache.xmlbeans.impl.values.XmlAnyTypeImpl
--> 04-20-06 18:35:48  WARN [http-8080-2] ResourceHandler: Found method named: create in service com.primagrid.test.one.testservice.ServicesAdminService with a single param of type: com.primagrid.test.one.testservice.CreateDocument , however the request param was of type: org.apache.xmlbeans.impl.values.XmlAnyTypeImpl
--> 04-20-06 18:35:48 DEBUG [http-8080-2] ProjectResourceBundle: org.apache.ws.resource.i18n.resource::handleGetObject(BAD_REQUEST_BODY_ELEMENT)
--> 04-20-06 18:35:48 DEBUG [http-8080-2] ResourceProvider: Sending SOAP fault: 
<?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:Client</faultcode>
   <faultstring>Unrecognized request body element: create@http://www.primagrid.com/test/one/testservice</faultstring>
   <detail/>
  </soapenv:Fault>
 </soapenv:Body>
</soapenv:Envelope>

Thanks in advance,
 
Asaf Lahav
VP R&D, Prima Grid LTD.
Cellular:  972-54-4717955
Phone:   972-3-6540255
Fax:       972-3-6540254