|
YOUR FEEDBACK
Did you read today's front page stories & breaking news?
SYS-CON.TV |
TODAY'S TOP SOA & WEBSERVICES LINKS Feature XML Acceleration: The Truth Behind the Myths - Don't assume that bandwidth and processing will be problems
XML Acceleration: The Truth Behind the Myths - Don't assume that bandwidth and processing will be problems
By: Dan Foody
Dec. 3, 2003 09:57 AM
As information technology professionals progress in their knowledge and use of XML and Web services, the question of XML performance persists. In hallway chats, one might hear that "XML takes up too much bandwidth" or "XML takes too many CPU cycles to process." Unfortunately, these beliefs lead to behaviors inconsistent with best practices for building and deploying Web service-based systems that will stand the test of time. These behaviors include continuing to operate with a proprietary non-XML architecture, and designing the architecture around network devices that do hardware XML processing. This article examines the myths that surround XML performance issues to help IT professionals avoid the pitfalls associated with the behaviors described above.
A Closer Look at XML Bandwidth So, what is it about XML that takes up so much bandwidth? There are really two separate issues. The first is that XML is text, which inherently takes up more space than binary formats. A 32-bit integer could be represented in 4 binary bytes, but take over 10 bytes when transmitted in text form (2.5X larger). The second is that XML is self-describing, which results in lots of repeating patterns of text. For example, each element name must be explicitly spelled out in both the start tag of the element and the end tag of the element. This adds a lot of extra repetitive text into the document. So, while there are distinct advantages to a self-describing message, it still consumes a lot of bandwidth on the WAN…or does it? The reality is that many organizations are starting to use hardware compression on their WAN links to reduce bandwidth consumption. And text has the highest compression ratio - in fact, text with lots of repetition can often be compressed 10X. XML is extremely compressible. So, if your WAN links are bandwidth constrained, you should probably be running compression - and if you are running compression, XML will be as efficient as other binary formats and potentially even more efficient since it's much more compressible than a binary stream.
CPU Cycles and XML But don't forget Moore's law - processing power is increasing rapidly, so what creates a bottleneck today will likely be inconsequential in the near future. Further, if the processing power for XML is a broadly recognized issue, it's highly likely that microprocessor vendors will add instructions to accelerate XML processing. Don't assume that XML processing performance will be limited by Moore's law - it's likely to surpass it if processing moves into the hardware.
Options for Boosting XML Performance Another option is to deploy a stand-alone "XML accelerator" appliance. Unfortunately, these don't actually provide the expected benefit. For example, many assume these appliances offload XML processing from the application - in fact they don't. An XML-based application still must parse the XML - there's no way to get around that. What XML accelerators can do very effectively is help convert XML in transit. For example, if a Web service application returns a purchase order in XML, an XML accelerator could convert that order to HTML very effectively. So, it might be better to consider these appliances "XSLT accelerators," since that's their most effective function. While they can perform some other forms of XML processing, generally there's little performance advantage in these cases - all of which weighs against the heavy disadvantage of the appliance as a "black box" that can't be managed or extended. One other alternative looks promising (though the market is still evolving). A number of companies are now building PCI hardware boards that accelerate XML processing. Unlike the appliance "XML accelerators" these boards plug into your application servers and take over the XML processing tasks from the main processor. They do this by plugging in an alternate "provider" under XML processing libraries that applications use (for example, the Java JAXP XML processor APIs). So, they can actually accelerate any XML-based application (whether developed in-house or purchased) transparently without any changes to the application or the network topology. If performance is critical, these hardware boards are a good tactical solution as you wait for Moore's law or the microprocessor vendors to catch up to your performance needs.
Conclusion XML JOURNAL LATEST STORIES . . .
SUBSCRIBE TO THE WORLD'S MOST POWERFUL NEWSLETTERS SUBSCRIBE TO OUR RSS FEEDS & GET YOUR SYS-CON NEWS LIVE!
|
SYS-CON FEATURED WHITEPAPERS MOST READ THIS WEEK BREAKING XML NEWS |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||