Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Re: Re: XSLT vs Templating, Part 2

by Matts (Deacon)
on Feb 07, 2002 at 16:10 UTC ( [id://143902]=note: print w/replies, xml ) Need Help??


in reply to Re: XSLT vs Templating, Part 2
in thread XSLT vs Templating, Part 2

OK, I hacked on this a bit. It seems that almost without a doubt the bottleneck is in XML::Generator::DBI (I added a tiny benchmark to the single sub, and generate took 11u, xslt took 1u and output took 1u. So I'm going to update it to SAX2, and make sure it goes faster. There's a lot of cruft in there, and I've learnt some about how to make DBI calls faster since I wrote it.

You can make things faster by simply changing your generator to:

my $generator = XML::Generator::DBI->new( Handler => XML::LibXML::SAX::Builder->new(), dbh => $dbh, RowElement => "monk" );
Which seems to work (even without updating XML::Generator::DBI). Then you have to add ->toString to your calls for the TT level stuff. It makes all three faster - by about 40%.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://143902]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others chanting in the Monastery: (4)
As of 2024-03-19 09:37 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found