You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ode.apache.org by Surendar <su...@7strata.com> on 2009/04/15 09:40:44 UTC

How to get the value from the Cdata using ode

Hi all,

I need to know , how to get the value from the cdata using ode.

iam sending input as string to the bpel, where that input contains one 
Cdata which looks like this

*<rawMessage>
<![CDATA[<Request xmlns='http://business'>
<uuid>uuid001</uuid>
<hostAddress>192.168.1.22</hostAddress>
<dummyMessage>dummyMessage</dummyMessage>
</Request>]]>
</rawMessage>

*see here my input parameter is rawMessage which contains the String as 
CDATA, know inside the bpel i want to get the value of hostAddress and 
send as Reply, how to do this in ode.



with regards

Surendar V

Re: How to get the value from the Cdata using ode

Posted by Paul Brown <pa...@gmail.com>.
On Wed, Apr 15, 2009 at 12:40 AM, Surendar <su...@7strata.com> wrote:
> I need to know , how to get the value from the cdata using ode.
> iam sending input as string to the bpel, where that input contains one Cdata
> which looks like this
> *<rawMessage>
> <![CDATA[<Request xmlns='http://business'>
> <uuid>uuid001</uuid>
> <hostAddress>192.168.1.22</hostAddress>
> <dummyMessage>dummyMessage</dummyMessage>
> </Request>]]>
> </rawMessage>
> *see here my input parameter is rawMessage which contains the String as
> CDATA, know inside the bpel i want to get the value of hostAddress and send
> as Reply, how to do this in ode.

Well, I hate to say it this way, but please, please don't do things
like that.  It's just not a good thing to do.  (Or, if it's a partner
or customer of yours who's doing this to you, that's not a good thing
for them to do...)

The CDATA directive says to the XML parser that the stuff between [
and ]]> is just plain text and to treat it that way, so that's what
ODE (or any other consumer that's on the other side of the XML parser)
sees.

I suggest that you create a service whose job it is to essentially
strip the "rawMessage" bits and send back the XML in the body as the
response.  Then ODE can get at the pieces.

I hope that makes sense...

-- 
paulrbrown@gmail.com
http://mult.ifario.us/