|
Hey everyone, I just committed a big update, but completely forgot to add
a comment to it. (Doh!) Anyhow, you might remember a few days ago I was discussing
ways that OO queries could be sped up. Well, I applied the technique I was
talking about. Namely, the OO query objects are really a façade which
implements the same interface (mostly) that the old OO queries did. But,
instead of validating the data it simply collects the data. I can then use the
portions of this data that aren’t variable (table names joins, columns,
where expressions (but not values), orders, etc) and make a hash that uniquely identifies
this query. Using that hash, which is actually quite quick to make, I
can check to see if a “rendered” version of the query exists on
disk. If so, I can use that rendered query, saving all the time in generating
the query. Otherwise, I can generate the query and write it to disk. The generation process takes just a little longer (I think,
I didn’t benchmark this) than the old way of creating the query
dynamically on each request. However, once the query is on disk this thing
blazes. A simple OO query that would do a select, set a mildly complex where
clause and an order clause used to take about 55 to 60 ms on average. Now the
average is 16ms or so. For those who are bad at math that’s roughly 3.5x
better performance. One thing of note is that the API did change slightly, but
only with obscure methods that I didn’t think anyone used. Let me know
if you run into problems with this. Also, just because I ran out of time. Reactor
doesn’t currently translate CF UUIDs to MSSQL GUIDs. I’m somewhat
tempted to drop this feature anyhow because it’s mssql specific and I’m
not sure how widely it’s being used. Doug -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- Reactor for ColdFusion Mailing List [email protected] Archives at: http://www.mail-archive.com/reactor%40doughughes.net/ -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- |
- [Reactor for CF] Big speed update in latest commit Doug Hughes
- Re: [Reactor for CF] Big speed update in latest commit Denny Valliant
- RE: [Reactor for CF] Big speed update in latest commit Doug Hughes
- RE: [Reactor for CF] Big speed update in latest commit Doug Hughes
- Re: [Reactor for CF] Big speed update in latest commit Tom Chiverton
- RE: [Reactor for CF] Big speed update in latest commit Doug Hughes
- Re: [Reactor for CF] Big speed update in latest commit Tom Chiverton
- RE: [Reactor for CF] Big speed update in latest commit Doug Hughes
- Re: [Reactor for CF] Big speed update in latest commit Barry Beattie
- RE: [Reactor for CF] Big speed update in latest commit Doug Hughes
- RE: [Reactor for CF] Big speed update in latest commit Doug Hughes
