Nope, I'm not sure. I know you can't use 'var' to protect the psuedo-scopes. My understanding is that they ended up in the variables scope, but that might be incorrect. If I'm right, then my solution would work.
However, if they're global to the request, then it doesn't matter, because you don't need to deal with concurrency in per-request scopes, because CF is single-threaded within a given request. The only potential issue would be if you're doing an isDefined() on one of the psuedo-scopes, which is bad idea, IMHO. cheers, barneyb On Tue, 10 Aug 2004 11:04:42 -0700, Spike <[EMAIL PROTECTED]> wrote: > Are you sure about this? > > As far as I remember, CFFILE is a global scope like URL, FORM, or REQUEST. I > don't think you can avoid concurrency by creating a one-time-use CFC. It's > been a while since I ran the tests, but I seem to remember that if you use a > CFC to perform file operations such as upload, you can access the cffile > scope from the calling page. I think that would indicate that the approach > you suggest below won't be thread safe. > > For CFFILE the only way I know to make it thread safe is to lock the access, > then take a duplicate of the CFFILE scope before closing the lock. > > I don't know about any of the other scopes Peter asked about though. > > Spike ---------------------------------------------------------- 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]
