OK...I'm having a problem.

I am using the Xerces XML Parser v 1.4.4
I have deployed my Service using the admin JSP like this:

ID - urn:mpd:purchaseOrder
Scope - Request
Provider - Type java
Provider Class - com.test.process.ProcessDirector
Use Static Class - false
Methods  - processPurchaseOrder

I am using the MessageRouter, not the RPCRouter.

Two things happen that I find very strange.

In the MessageRouter Servlet, 3 of the lines in the doPost method are as
follows:
         Element e = (Element) body.getBodyEntries().elementAt (0);
                        ...
       String targetID = e.getNamespaceURI ();
       String messageName = e.getLocalName ();


The first issue I have is that in order to get the 'targetID' in the first
statement above you must have namespace qualified the first bodyElement.
That goes against the SOAP 1.1 specification, and it seems really arbitrary
to have to qualify the first body element and not the others (which it
doesnt seem to process anyways, but I havent looked into it too far)???
What am I missing about that code?  Should the first element be the body
itself?  If so something else is funny here because it's not in my case.

The next issue I have, which may be solved when/if the first one can be is
that if I do namespace qualify the first body element so that I can get a
targetID using a urn that I am using for the deployed web service, the
second statement listed above resolves to the element name of the first body
element...so when it tries to find the method for my deployed service, it is
looking for a value that doesn't exist.

Here is a sample of the data that is sent in the post.

<?xml version='1.0' encoding='UTF-8'?>
<SOAP-ENV:Envelope
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/";
xmlns:xsi="http://www.w3.org/1999/XMLSchema-instance";
xmlns:xsd="http://www.w3.org/1999/XMLSchema";>
        <SOAP-ENV:Body xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/";>
                <t:MyEnvelope xmlns:t="urn:mpd:purchaseOrder">
                        . . . . . .
                </t:MyEnvelope>
        </SOAP-ENV:Body>
</SOAP-ENV:Envelope>


I think I have to be doing something very basic wrong or else I would be
able to find some information on this issue in the archives, but I cant.  I
have tried RPC and it works fine....this is just drivin me crazy.

Any issue would be greatly appreciated.

Thanks,
Mike

Reply via email to