r
Radu Maierean
JamboTECH
phone: 818-676-3452
email: radu at jambotech.com
-----Original Message-----
From: owner-xmlblaster at server.xmlBlaster.org
[mailto:owner-xmlblaster at server.xmlBlaster.org] On Behalf Of Marcel Ruff
Sent: Friday, November 12, 2004 2:01 PM
To: xmlblaster at server.xmlBlaster.org
Subject: Re: [xmlblaster] message payload affected by the transport
protocol?...
Radu Maierean wrote:
hi,
for a quick test of an application that i am working on, i used the
demo found under
xmlBlaster/demo/javaclients/script/XmlScript.java
i tried to send this in the message payload:
<Sometag attribute="'single-quoted-value'"/>
what i received at the other end was:
<Sometag attribute=''single-quoted-value''/>
that means:
A. the message payload (or "contents", as you name it in the docs)
just happens to be an XML string B. the value of one of my attributes
in the payload contains single quotes, and therefore the attribute
delimitation marks are double quotes C. either the demo java app, or
the XmlBlaster server, decided to interpret my message payload and to
replace the double quotes of my attribute delimiter with single quotes
D. result: the payload that i receive at the other end is not an XML
proper string anymore. (or at least expat, which is the xml parser
that
crunches the message payload, cannot help me with this string.)
my understanding is that the payload of a message can be a blob, so it
only has to be passed over; it shouldnt be affected in any way by any
kind of processing. now if this replacement of single quotes with
double quotes takes place in the java demo, i wouldnt mind too much;
but if the XmlBlaster server is the one that does this, i'm in big
trouble...
can any of you tell me who is modifying my message? escaping the
double quotes with " doesnt help either... thanks.
No, the server won't touch it (only if you add a mime plugin and do it
with purpose), try this:
java javaclients.HelloWorldPublish -content "<Sometag
attribute=\"'single-quoted-value'\"/>"
java javaclients.HelloWorldSubscribe -xpath //key
The XmlScript parser does it, we should add CDATA support to it so that
we are able to send:
<xmlBlaster>
<connect/>
<publish>
<key oid="1">
<content><![CDATA[<Sometag
attribute="'single-quoted-value'"/>]]</content>
</publish>
<disconnect />
</xmlBlaster>
regards
Macel
r
Radu Maierean
JamboTECH
phone: 818-676-3452
email: radu at jambotech.com
I haven't tried it but i think it's the client side script parser which