Using the literal, like this:

<cflock name="myapplication" etc...>

makes sense to me given my understanding of cflock; does anyone understand
why Allaire Tech support explicitly recommends 

<cflock name="#application.applicationname#" etc..>

instead?  

The also recommend <name="#session.sessionid#"> when locking session vars;
do you agree, or if not, what do you recommend?

-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, July 12, 2000 5:46 PM
To: [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Subject: RE: CFLOCK and server variables


> Ok, I've seen that (in 4.01) I should use #application.applicationname#
> for the CFLOCK "name" when locking application variables;

I've seen this too, but don't recommend it. The variable
Application.ApplicationName is an Application variable, and should only be
referenced within a lock! I'd instead recommend that you simply use the
literal value that you put in your CFAPPLICATION tag for the name. So, if
you've got <cfapplication name="foo" ...>, use <cflock name="foo" ...> to
lock application variables. As long as you're consistent about this, you'll
be OK.

The preceding only applies to CF 4.0.x, of course. Gotta love the SCOPE
attribute in CF 4.5.x.

> what do I use for locking server variables?

The literal string "server" will do just fine. Again, as long as you're
consistent in doing this across applications, you'll be OK.

Dave Watts, CTO, Fig Leaf Software
http://www.figleaf.com/
voice: (202) 797-5496
fax: (202) 797-5444

----------------------------------------------------------------------------
--
Archives: http://www.mail-archive.com/[email protected]/
To Unsubscribe visit
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or
send a message to [EMAIL PROTECTED] with 'unsubscribe' in
the body.
------------------------------------------------------------------------------
Archives: http://www.mail-archive.com/[email protected]/
To Unsubscribe visit 
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or send a 
message to [EMAIL PROTECTED] with 'unsubscribe' in the body.

Reply via email to