You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by gargankur007 <ga...@gmail.com> on 2015/06/11 19:45:25 UTC

Removing namespaces from soap response using SoapOutInterceptor

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
    <soap:Body>
        <ns2:RmhpHop3PaymentEffResponse
xmlns:ns2="http://wem-rmhpimpl.demo.hcentive.com:9090/wsx/services/WemRmhpHop3PaymentEffectuationService"/>
    </soap:Body>
</soap:Envelope>
This is current outcome I need 

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
    <soap:Body>
        <RmhpHop3PaymentEffResponse/ >
    </soap:Body>
</soap:Envelope>
Can this be achieved through any SoapOutInterceptor?







--
View this message in context: http://camel.465427.n5.nabble.com/Removing-namespaces-from-soap-response-using-SoapOutInterceptor-tp5768110.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: Removing namespaces from soap response using SoapOutInterceptor

Posted by François LIOT <fr...@poplidays.com>.
Hi,

I wouldn't pretend it's a clean solution, but at least it works....

<transform><simple>${body.replace("xmlns:xsi=", "remove1=")}</simple></transform>
<transform><simple>${body.replace("xmlns:xsd=", "remove2=")}</simple></transform>
<transform><simple>${body.replace("xmlns=", "remove3=")}</simple></transform>
....

Regards,

François Liot

 ​

________________________________________
From: Claus Ibsen <cl...@gmail.com>
Sent: Saturday, June 13, 2015 9:09 AM
To: users@camel.apache.org
Subject: Re: Removing namespaces from soap response using SoapOutInterceptor

Hi

You can ask on Apache CXF user list

On Thu, Jun 11, 2015 at 7:45 PM, gargankur007 <ga...@gmail.com> wrote:
> <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
>     <soap:Body>
>         <ns2:RmhpHop3PaymentEffResponse
> xmlns:ns2="http://wem-rmhpimpl.demo.hcentive.com:9090/wsx/services/WemRmhpHop3PaymentEffectuationService"/>
>     </soap:Body>
> </soap:Envelope>
> This is current outcome I need
>
> <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
>     <soap:Body>
>         <RmhpHop3PaymentEffResponse/ >
>     </soap:Body>
> </soap:Envelope>
> Can this be achieved through any SoapOutInterceptor?
>
>
>
>
>
>
>
> --
> View this message in context: http://camel.465427.n5.nabble.com/Removing-namespaces-from-soap-response-using-SoapOutInterceptor-tp5768110.html
> Sent from the Camel - Users mailing list archive at Nabble.com.



--
Claus Ibsen
-----------------
Red Hat, Inc.
Email: cibsen@redhat.com
Twitter: davsclaus
Blog: http://davsclaus.com
Author of Camel in Action: http://www.manning.com/ibsen
hawtio: http://hawt.io/
fabric8: http://fabric8.io/

Re: Removing namespaces from soap response using SoapOutInterceptor

Posted by Claus Ibsen <cl...@gmail.com>.
Hi

You can ask on Apache CXF user list

On Thu, Jun 11, 2015 at 7:45 PM, gargankur007 <ga...@gmail.com> wrote:
> <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
>     <soap:Body>
>         <ns2:RmhpHop3PaymentEffResponse
> xmlns:ns2="http://wem-rmhpimpl.demo.hcentive.com:9090/wsx/services/WemRmhpHop3PaymentEffectuationService"/>
>     </soap:Body>
> </soap:Envelope>
> This is current outcome I need
>
> <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
>     <soap:Body>
>         <RmhpHop3PaymentEffResponse/ >
>     </soap:Body>
> </soap:Envelope>
> Can this be achieved through any SoapOutInterceptor?
>
>
>
>
>
>
>
> --
> View this message in context: http://camel.465427.n5.nabble.com/Removing-namespaces-from-soap-response-using-SoapOutInterceptor-tp5768110.html
> Sent from the Camel - Users mailing list archive at Nabble.com.



-- 
Claus Ibsen
-----------------
Red Hat, Inc.
Email: cibsen@redhat.com
Twitter: davsclaus
Blog: http://davsclaus.com
Author of Camel in Action: http://www.manning.com/ibsen
hawtio: http://hawt.io/
fabric8: http://fabric8.io/

Re: Removing namespaces from soap response using SoapOutInterceptor

Posted by sathiyaraja <sa...@hotmail.com>.
Hi, 
You can do this by xsl transformation.,

PFB xsl for removing namespace from a xml message.,


<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
  <xsl:output omit-xml-declaration="yes" indent="yes"/>

  <xsl:template match="*">
    <xsl:element name="{local-name(.)}">
      <xsl:apply-templates select="@* | node()"/>
    </xsl:element>
  </xsl:template>
  <xsl:template match="@*">
 </xsl:template>
</xsl:stylesheet>

Regards,
Sathiya



--
View this message in context: http://camel.465427.n5.nabble.com/Removing-namespaces-from-soap-response-using-SoapOutInterceptor-tp5768110p5768213.html
Sent from the Camel - Users mailing list archive at Nabble.com.