On Friday one of the developers from Sun’s Fast WebService team, Santiago Pericas-Geertsen, posted a blog entry that included a reference to our work on IAP. I’m a big fan of Fast Infoset (FI), which is the technology and standard that is driving the Fast WebServices and the binary XML movement. This technology is a binary representation of an XML schema instance document that allows the format of the data to be expressed using XML schema, while still allowing for binary data to be sent as part of the document. Additionally, the documents are more compact and simpler to parse providing a large performance improvement.
This technology is truly the next generation for remoting and data transfer because it provides the ability to use all the good features of XML and XML schema without the binary limitations, which traditionally have plagued that technology. Additionally, the team of developers working on the FI project over at Java.net truly understand use cases for this technology.
A simple illustration of the great work the FI team is doing is that their FI parser is able to correctly handle an FI document from a InputStream without requiring an end-of-stream to determine that the FI document has ended. This makes it obvious that these developers understand that streaming XML or multiple documents on a single stream are going to be common applications for FI. Without mangling the stream at all, they can effectively read any number of FI documents from it.
We decided a while back, after comparing the performance of encoding simple JPEG images into a standard XML document and pushing them across the wire versus using a binary stream, to switch to FI. We found that since standard XML required that binary data be base 64 encoded and decoded, pushing images and other binary values across the wire had such a negative impact on performance that another solution was required. This is when we started evaluating Fast Infoset and found that it worked extremely well and required few changes to our existing code.
Here is the link to the blog entry that highlights the use of FI in IAP:
http://weblogs.java.net/blog/spericas/archive/2005/10/fast_infoset_in.html
Also, here is the link to the FI project whose parser and serializer we are using: