no one is forking off threads... thread safety is necessary because (especially in mach-ii's case) many CFC's are application-scoped, so any request is using the same instance of that CFC. CFC's need to be thread safe because the server will simultaneously process many requests at a time, and if multiple requests hit the same cffunction on the same cfc instance at the same time, they need to have their own set of function-local variables (hence the need to "var" everything, even iterators and query names).
-Dave >>> [EMAIL PROTECTED] 8/10/2004 9:32:21 AM >>> I'm curious: how are you forking off threads inside of a CFC? Using the Java methods? On Mon, 9 Aug 2004 11:31:09 -0700, Sean Corfield <[EMAIL PROTECTED]> wrote: > On Mon, 09 Aug 2004 14:19:37 -0400, Peter J. Farrell > <[EMAIL PROTECTED]> wrote: > > I know this is slightly OT, but I'm writing some CFCs and doing some > > things in them that I don't usually use all the often. What exactly in > > CFMX is thread-safe at the moment or more specifically regarding CFHTTP, > > CFPOP, CFFILE? > > In order to be thread-safe, your code needs to declare *all* local > variables used in a function with 'var'. That includes tags that > implicitly create their own variables - CFHTTP is a good example. > However, some tags' implicit variables cannot be declared with 'var' > (bug in CFMX) so you need to be careful. > > Check out my blog post on this subject and the ensuing comments: > > http://www.corfield.org/blog/past/2004_02.html#000307 > -- > Sean A Corfield -- http://www.corfield.org/blog/ > > "If you're not annoying somebody, you're not really alive." > -- Margaret Atwood > > > ---------------------------------------------------------- > You are subscribed to cfcdev. To unsubscribe, send an email > to [EMAIL PROTECTED] with the words 'unsubscribe cfcdev' > in the message of the email. > > CFCDev is run by CFCZone (www.cfczone.org) and supported > by Mindtool, Corporation (www.mindtool.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' in the message of the email. CFCDev is run by CFCZone (www.cfczone.org) and supported by Mindtool, Corporation (www.mindtool.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' in the message of the email. CFCDev is run by CFCZone (www.cfczone.org) and supported by Mindtool, Corporation (www.mindtool.com). An archive of the CFCDev list is available at www.mail-archive.com/[EMAIL PROTECTED]
