Re: [xml] exchanging xml over a network



I'm interested in exchanging streamed xml data over a network.

An interesting question with remarkably subtle implications.

At the simplest level, XML is its own serialization, so just open a 
socket, blat the document, and read the response.  But now you have to 
worry about framing -- how does the receiving side now that the sender is 
done?  It's hard to do without tying the XML parser closely into the 
socket layer.  And if you decide you want more than one document flowing 
over a connection, you really need a true framing protocol.  I strongly 
suggest that unless you have a good reason to avoid it, just use HTTP. 
Support is pretty universal, so you have less code of your own to write.

Someone mentioned SOAP.  That can also get you some nice features, but 
beware that there are issues with embedding one XML document inside 
another. On the other hand, if you (eventually) want to do things like 
security, reliability, etc., you might want to just leverage parts of the 
(growing bigger than you think, ugh) web services stack and use SOAP.

Hope this helps.

        /r$

--
SOA Appliances
Application Integration Middleware




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]