Hi,

by default, Axis2 seems to put namespace declarations like 
'xmlns:ns="http://my.namespace.com/this/one/is/it";' at the latest / 
deepest point in the XML possible, which seems to be perfectly in line 
with W3C requirements.

My SOAP client has to talk to the Web Service via a XML security gateway 
(probably Cisco ACE XML gateway) which is configured to require all 
namespaces of the request to be declared in the SOAP envelope.

How can I achieve that using Axis2 1.4.1?

Environment: 
- IBM WebSphere Application Server 6.0.2 / IBM Java 1.4.2 JRE (stuck to)
- Axis2 1.4.1 / XMLbeans 2.3.0 (only for client operation)


Examples:


That is what Axis2 currently produces, using simply the generated Java 
stub class:

<?xml version='1.0' encoding='UTF-8'?>
<soapenv:Envelope 
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/";>
<soapenv:Header>
        <Request xmlns="http://premconn.premiereconnect.com/2007/02"; 
soapenv:mustUnderstand="0">
                <ReceiverKey>http://my.receiver.key/</ReceiverKey>
                <RequestID>f0aFQR5s_AIBYHgdN16pqlf</RequestID>
                <Authentication>
                        <XDDSAuth>
                                <RequesterID>###</RequesterID>
                                <Password>***</Password>
                        </XDDSAuth>
                </Authentication>
        </Request>
</soapenv:Header>
<soapenv:Body>
        <ns:ListCreateRequest 
xmlns:ns="http://premconn.premiereconnect.com/2007/02";>
                <ns:SubmitId>f0aFQR5s_AIBYHgdN16pqlf</ns:SubmitId>
etc. etc. etc.


And *that* is what ACE XML gateway seems to expect:

<?xml version='1.0' encoding='UTF-8'?>
<soapenv:Envelope 
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"; 
xmlns:ns="http://premconn.premiereconnect.com/2007/02";>
<soapenv:Header>
        <ns:Request soapenv:mustUnderstand="0">
                <ns:ReceiverKey>http://my.receiver.key/</ns:ReceiverKey>
                <ns:RequestID>f0aFQR5s_AIBYHgdN16pqlf</ns:RequestID>
                <ns:Authentication>
                        <ns:XDDSAuth>
                                <ns:RequesterID>###</ns:RequesterID>
                                <ns:Password>***</ns:Password>
                        </ns:XDDSAuth>
                </ns:Authentication>
        </ns:Request>
</soapenv:Header>
<soapenv:Body>
        <ns:ListCreateRequest>
                <ns:SubmitId>f0aFQR5s_AIBYHgdN16pqlf</ns:SubmitId>
etc. etc. etc.


How can I force Axis2 to produce output that conforms to these 
requirements?


Maybe this is related to Jira #AXIS2-4215 , URL: 
https://issues.apache.org/jira/browse/AXIS2-4215


Thanks in advance for useful hints and help,
-- 
Dipl.-Inform. Christian Gosch, PMI PMP
Systems Architecture, Project Management

inovex GmbH
Büro Pforzheim
Karlsruher Strasse 71
D-75179 Pforzheim
Tel: +49 (0)7231 3191-85
Fax: +49 (0)7231 3191-91
c.go...@inovex.de
www.inovex.de

Sitz der Gesellschaft: Pforzheim
AG Mannheim, HRB 502126
Geschäftsführer: Stephan Müller 



Reply via email to