> 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?
Well, I think that when they introduced CFLOCK, the developers thought that
this would be a workable method. They later realized the inherent problem,
and added the SCOPE attribute in CF 4.5. However, the tech support guys have
continued to work with what they've been given.
It's unfortunate that the whole locking issue has worked out the way it has.
First, we had memory variables but no locking in CF 3.x, which caused
problems under heavy load. Then, the CFLOCK tag was introduced, but without
clear guidance on how to use it, and a problematic naming convention. Now,
things seem to be a bit better, but there still isn't a clear, complete
description from Allaire about how to use locking with CFLOCK and with the
CF Administrator locking options. People have had to piece together bits of
information to figure out the best way, and all I've done is collect those
pieces and try to explain them as best I can. It may still be the case that
next year, there's a "better way" according to Allaire.
> The also recommend <name="#session.sessionid#"> when locking
> session vars; do you agree, or if not, what do you recommend?
No, again, this causes the same problem. You want a unique name to apply to
an individual session, but you don't want to store it in a session variable.
If you're using CF's cookies for state management, you could do this:
<cflock name="#Cookie.CFID##Cookie.CFTOKEN#" ....>
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.