Skip to Content.
Sympa Menu

xom-interest - re: re: [XOM-interest] Serializing objects that contain an instance of nu.xom.Document, part II

xom-interest AT lists.ibiblio.org

Subject: XOM API for Processing XML with Java

List archive

Chronological Thread  
  • From: Elliotte Rusty Harold <elharo AT metalab.unc.edu>
  • To: "Brian Sam-Bodden" <bsbodden AT integrallis.com>
  • Cc: xom-interest AT lists.ibiblio.org
  • Subject: re: re: [XOM-interest] Serializing objects that contain an instance of nu.xom.Document, part II
  • Date: Fri, 20 Feb 2004 08:29:38 -0500

At 7:18 PM -0800 2/19/04, Brian Sam-Bodden wrote:
Rusty,
I haven't done a pound per pound comparison of
marshalling versus parsing. But in most of our
scenarios the object is already in memory so there is
no marshalling involved and we get it by reference.

If it's already in memory, why do you need to serialize and reparse it at all? Wouldn't you have the unserialized XOM object handy?

The
problem is that to get it to some of these caches it
needs to be serializable. Even if it gets to go through
a round of marshalling/demarshalling to get to the
cache it is still better than for each client that
accesses the object to have to parse the XML again.

Again I ask you, how do you know that? What evidence do you have that marshalling/unmarshalling is faster than serializing/parsing? You're making an assumption here that I've seen no evidence for. Object serialization in Java has a long history of being dog slow. if you want to claim it's faster than XML parsing you're going to have to measure it.
--

Elliotte Rusty Harold
elharo AT metalab.unc.edu
Effective XML (Addison-Wesley, 2003)
http://www.cafeconleche.org/books/effectivexml
http://www.amazon.com/exec/obidos/ISBN%3D0321150406/ref%3Dnosim/cafeaulaitA




Archive powered by MHonArc 2.6.24.

Top of Page