Compress XML.

J

Joseph Kesselman

The usual way to compress XML is just to put it through a standard
text-compression tool such as zip/gzip. That compresses both structure
and content very effectively. But that produces binary data, which would
have to be encoded (eg base-64 encoding) before it could be wrappered in
XML, and that encoding of course adds some space overhead back in.

I don't know of any other standard way of compressing a SOAP payload.
 
J

Joseph Kesselman

Actually, a better answer would be to embed the XML within the SOAP
envelope, compress the whole thing, send the binary, and decompress it
before trying to interpret the message as SOAP. But I don't know whether
any of the common SOAP tools would support that.
 
C

Cydrome Leader

Joseph Kesselman said:
The usual way to compress XML is just to put it through a standard
text-compression tool such as zip/gzip. That compresses both structure
and content very effectively. But that produces binary data, which would
have to be encoded (eg base-64 encoding) before it could be wrappered in
XML, and that encoding of course adds some space overhead back in.

I don't know of any other standard way of compressing a SOAP payload.

Is there anything that isn't lame about xml?

- bloat your data into text, extremely verbose text
- add lots of tags, let's say twice as many as needed
- compress it into binary
- then turn it back into text
- then put more tags around it

What the ****?
 
J

Joe Kesselman

Cydrome said:
Is there anything that isn't lame about xml?

Lots. If you're interested, websearch.

XML syntax is not intended to be terse. It's intended to be an
easily-toolable, easily-debuggable interchange format -- and has
succeeded well enough to kill off several binary interchange formats,
because in fact terseness is overrated for that set of tasks. XML has
served as a coalescence point for a whole bunch of useful technology
which was previously trapped in its own little non-interchangable corners.

If you're looking for a back-end data format, XML syntax isn't it...
though depending on your needs, the XML data model may be. See, for
example, the pureXML features in IBM's DB2 database product, which
directly express the XML Infoset -- that isn't just because XML is
trendy, it's because XML is *USEFUL* as a set of concepts.

XML is a tool. Not all tools suit all tasks. If it isn't the right tool
for your purposes, that's fine; some applications really do run in a
vaccuum and talk only to themselves, and for those XML is probably not
the right answer... unless they want the convenience of being able to
leverage other apps and existing libraries rather than reinventing some
of these wheels.
 
P

Peter Flynn

Is there anything that isn't lame about xml?

- bloat your data into text, extremely verbose text - add lots of tags,
let's say twice as many as needed - compress it into binary
- then turn it back into text
- then put more tags around it

What the ****?

There are few things more pitiable than a programmer who doesn't grok
markup.

///Peter
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,766
Messages
2,569,569
Members
45,042
Latest member
icassiem

Latest Threads

Top