But Matt's point is extremely valid and I think a technique way to many developers overlook too consider with "keeping the code dynamic." Caching can mean many things, on a heavily trafficked site, cache portions of content for seconds can increase performance of the box tenfold, without losing the benefits of dynamic content.
Also, I can't count the times I've heard someone complain about a page taking 30-60 seconds to come up and after looking at it, it's some page doing monthly reporting over achieved data. Granted, you can almost always find ways to knock down processing time like that, but by simply running the script one time in the middle of the night when the archived data is needed and caching the page as a static page, you'll save you safe tons of processing time and look like a genius. And if you're saying, well you can't always cache content to a static page, they want to be able to dynamically manipulate the data. Well then cache the data instead of the output. There are a number of ways you can cache CF code, but if its db results, then store everything in archived tables that contain the content post-calculations. The bottom line is caching is one of the few ways to make even bad code perform well, and it just makes good code perform better. -Dan > -----Original Message----- > From: Jochem van Dieten [mailto:[EMAIL PROTECTED]] > Sent: Wednesday, September 18, 2002 4:21 AM > To: CF-Talk > Subject: Re: code optimization (was RE: Jsp Vs Cfm (CFMX) -- Test Code) > > Matt Liotta wrote: > > > > Every idea/technique that has been suggested thus far for code > > optimization is a waste of time for almost all applications. Sure some > > of these ideas/techniques code save a few milliseconds here and there, > > but they offer very small gains in scalability. There are much simpler > > ways to achieve greater scalability in less time than code optimization > > e.g. caching. I suggest people spend their time seeking out these ways > > instead of spending time on code optimization. > > As you said it yourself (it was you, right?) there is a difference > between performance and scalability. And I think most people are > discussing performance here. > > > > You should only spend > > time on code optimization after every other performance enhancement has > > been tried. > > Remember the example I gave where switching from treating a long Base64 > string as a string to treating it as an array gave a performance > increase of a factor 4000. I have helped somebody else convert from > using ListDeleteAt() to ArrayDeleteAt() and get a 100 fold performance > increase. Sometimes code optimization is what you need. > > But I have to admit, compared to those code optimizations, the quality > of some of the SQL, and some of the ridiculous algorithms I see, a > factor 8 between JSP and CFML in the generated java is peanuts. > > Jochem > > ______________________________________________________________________ Your ad could be here. Monies from ads go to support these lists and provide more resources for the community. http://www.fusionauthority.com/ads.cfm FAQ: http://www.thenetprofits.co.uk/coldfusion/faq Archives: http://www.mail-archive.com/[email protected]/ Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

