Alain, By default CFC's are compiled into bytecode, so recompilation will not take place. If you get 100 concurrent users on the CFC, disk cache speeds up reading (as well as CFMX internal cache) and even then, mostly 100 concurrent users means you are in full control of the machine.
If people don't want to enable session management, that's fine with them, but then they should take the consequences of less performance :) ColdFusion templates are stateless unless specified, so the template starts, executes, and shuts down. Micha Schopman Project Manager Modern Media, Databankweg 12 M, 3821 AL Amersfoort Tel 033-4535377, Fax 033-4535388 KvK Amersfoort 39081679, Rabo 39.48.05.380 ------------------------------------------------------------------------ ------------------------------------------------------------------------ ----- Modern Media, Making You Interact Smarter. Onze oplossingen verbeteren de interactie met uw doelgroep. Wilt u meer omzet, lagere kosten of een beter service niveau? Voor meer informatie zie www.modernmedia.nl ------------------------------------------------------------------------ ------------------------------------------------------------------------ ----- -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Alan Williamson Sent: vrijdag 18 maart 2005 14:14 To: [email protected] Subject: [CFCDev] Should the underlying engine not be caching CFC objects? Morning, My biggest gripe with CFC's is the fact that for every request i am creating a new object, an object that is identical in nature to every other request to that page. So for example if i take one of the sample CFC's found on CFCDEV (http://www.cfczone.org/cfcs/) then if i have 100 concurrent requests to a page that uses a given CFC, then thats 100 objects i have created, where the 1 would have done. Yes, I could cache them in SESSION/APPLICATION etc but thats overhead and placing the responsibility on me, the CFML developer. I might not even have a [session/application] scope available to me at that time. If somehow we could 'pool' object instances then this would reduce memory/speed greatly. For the applications i am working on it would increase the overall performance significantly. So for example, one could create pooled versions of a CFC: <cfset myCFC = CreateCFC("my.mycfc")> Where this object would not be created every time, but a reference passed back to the one object passed back to it. The majority of the CFC's are not holding data per-se but operating on data passed in; very much how we use to work with custom-tags in their hey day. Custom-tags only had one instance in the 100concurrent page scenario. Let the underlying engine worry about the object instances; if I create an object using CreateObject() then its business as usual. But I create it with CreateCFC() then its a pool object, that will be shared. It may not exist, as the underlying engine would be allowed to only keep the last x number of used CFCs and create new ones on demand. Love to hear your thoughts on this topic. thx -- Alan Williamson, City Planner w: http://www.BLOG-CITY.com/ b: http://alan.blog-city.com/ e: [EMAIL PROTECTED] p: http://www.blog-city.com/profiles/9.htm ---------------------------------------------------------- You are subscribed to cfcdev. To unsubscribe, send an email to [email protected] with the words 'unsubscribe cfcdev' as the subject of the email. CFCDev is run by CFCZone (www.cfczone.org) and supported by CFXHosting (www.cfxhosting.com). An archive of the CFCDev list is available at www.mail-archive.com/[email protected] ---------------------------------------------------------- You are subscribed to cfcdev. To unsubscribe, send an email to [email protected] with the words 'unsubscribe cfcdev' as the subject of the email. CFCDev is run by CFCZone (www.cfczone.org) and supported by CFXHosting (www.cfxhosting.com). An archive of the CFCDev list is available at www.mail-archive.com/[email protected]
