Return-Path: Mailing-List: contact general-help@xml.apache.org; run by ezmlm Delivered-To: mailing list general@xml.apache.org Received: (qmail 8637 invoked from network); 10 May 2000 00:47:21 -0000 Received: from pt73.peacetech.com (HELO ptint3.peacetech.com) (207.176.93.73) by locus.apache.org with SMTP; 10 May 2000 00:47:21 -0000 Received: by pt73.peacetech.com with Internet Mail Service (5.5.2448.0) id <2AWMPG10>; Tue, 9 May 2000 20:47:15 -0400 Message-ID: <511F5E23FD70D111BA840060083424E5B6DB39@pt73.peacetech.com> From: "Roytman, Alex" To: "'general@xml.apache.org'" Cc: "'arkin@exoffice.com'" Subject: RE: XMLSerializer performance Date: Tue, 9 May 2000 20:47:14 -0400 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.5.2448.0) Content-Type: text/plain; charset="iso-8859-1" X-Spam-Rating: locus.apache.org 1.6.2 0/1000/N Assaf, I ran my tests with new 1.0.4 build Arnaud put on the web server. Performance is much better - the same as Xalan's serializer Thanks for your help And Arnaud thank you for new 1.0.4 build Alex -----Original Message----- From: Arkin [mailto:arkin@exoffice.com] Sent: Tuesday, May 09, 2000 6:14 PM To: general@xml.apache.org Subject: Re: XMLSerializer performance You need to get the serializers from the CVS (can someone do a 1.0.4). The new ones separate the indentation and no-indentation printers, and so should run way faster. arkin "Roytman, Alex" wrote: > > Hello Assaf, > > Thank you for such a quick reply. > > I am using version 1.0.3 and no I do not have > org.apache.xml.serialize.Printer class > I instantiated XMLSerializer directly > > I run it on Windows NT with Server HotSpot JVM > > I would imagine you've done lots of work to make it fast. > I am switching from Oracle XML to Apache and still have plenty to learn. So > what do I do wrong :-)? > > Alex > > -----Original Message----- > From: Arkin [mailto:arkin@exoffice.com] > Sent: Tuesday, May 09, 2000 5:54 PM > To: general@xml.apache.org > Cc: 'xerces-j-dev@xml.apache.org' > Subject: Re: XMLSerializer performance > > We intentionally made the serialiers inefficient so we'll have something > to work on :-) > > Seriously, the serializers should be damn optimized with identation off. > In the test cases I run I compare them to println() and I get 100% > overhead, probably 50/50 between the use of SAX events and the > serializer state management. (RedHat 6.0, Sun JDK 1.2.2 with JIT) > > Which version of Xerces are you using, or are you using the CVS version? > Do you have a class called org.apache.xml.serialize.Printer? > > arkin > > "Roytman, Alex" wrote: > > > > > Hello, > > > > > > What is the most efficient way (in terms of speed and memory) to > serialize > > > SAX or DOM? > > > I did some performance tests and was very surprised that the > XMLSerializer > > > showed the pretty poor results: > > > > > > Actual time does not matter I would like to show relative times > > > > > > SAX -> XMLSerializer -> XML File 5 sec > > > SAX -> Xalan serializer -> XML File 2 sec > > > SAX -> Xalan stylesheet -> XML File 6 sec > > > Oracle DOM print() -> XML File 3 sec > > > Oracle Stylesheet -> XML File 9 sec > > > > > > As you can see XMLSerializer is almost as slow as applying a Xalan > > > stylesheet and 2.5 times slower than Xalan serializer and almost twice > as > > > slow as Oracle serializer. This is with INDENT OFF. > > > > > > May be did something wrong or I suppose to use some other means to > > > serialize my SAX events. In my case I do not need pretty serialization > or > > > serialization to HTML or something else - I need PERFORMANCE. > Serializing > > > SAX or DOM is a fundamental operation - we need to get the best > > > performance we can. I would be grateful if you can suggest any other > means > > > of serializing SAX (DOM) > > > I also read somewhere that Xalan serializer will be deprecated and > > > replaced with org.xml.serializer package. Is it true? > > > > > > Thank you in advance > > > > > > Alex Roytman > > > Peace Technology, Inc. > > > (301) 206-9696 > > > > > > > > > > --------------------------------------------------------------------- > > In case of troubles, e-mail: webmaster@xml.apache.org > > To unsubscribe, e-mail: general-unsubscribe@xml.apache.org > > For additional commands, e-mail: general-help@xml.apache.org > > -- > ---------------------------------------------------------------------- > Assaf Arkin www.exoffice.com > CTO, Exoffice Technologies, Inc. www.exolab.org > > --------------------------------------------------------------------- > In case of troubles, e-mail: webmaster@xml.apache.org > To unsubscribe, e-mail: general-unsubscribe@xml.apache.org > For additional commands, e-mail: general-help@xml.apache.org > > --------------------------------------------------------------------- > In case of troubles, e-mail: webmaster@xml.apache.org > To unsubscribe, e-mail: general-unsubscribe@xml.apache.org > For additional commands, e-mail: general-help@xml.apache.org -- ---------------------------------------------------------------------- Assaf Arkin www.exoffice.com CTO, Exoffice Technologies, Inc. www.exolab.org --------------------------------------------------------------------- In case of troubles, e-mail: webmaster@xml.apache.org To unsubscribe, e-mail: general-unsubscribe@xml.apache.org For additional commands, e-mail: general-help@xml.apache.org