Jim wrote:

> Tim, we have been generally disappointed at the speed of parsing an
XML file
> of any significance. I like the ideas behind it, but I think most of the
> more widely-used XML parsers suffer from some speed issues.

Some of the parsing performance issues stem from the use of generic
parsers (either DOM or SAX based, though the latter is much faster).

If you are using XML as a transport layer between different application
layers (say the Servlet engine and the App Server, or between internal
systems), and thus "control" both ends of the pipe, there are much
more efficient ways to do the parsing.

First, since you own both sides, you can usually dispense with DTD's
and the attendant overhead of validation.  (Obviously this is not the
case when you are going cross-corporation through the net....as in
B2B and such).  Dropping validation tends to buy you a lot in
performance improvement.

Furthermore, it is also possible to use a code-generator to build
specific XML encode/decode methods which will outperform a generic
parser by a great margin.  We built our own dictionary-based code
generator to do this, but Sun also has a project, code named
"Adelard", that will do XML data binding and validation to Java objects.
Worth a look at:

http://java.sun.com/xml/docs/binding/DataBinding.html

Of course, if you are shipping XML across the net, or between
companies these approaches are not going to help much....


...Andrzej, Chaeron Consulting Corporation

Chaeron:    http://www.chaeron.com

===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff EJB-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

Reply via email to