> Is it possible to use named locks with dynamic names?

Yes.

> So I was thinking about doing a named lock with a dynamic name based
> on the domain... ie:
>
> <cflock name="appInitLock2_#replace(request.domain,".","","ALL")#"
> type="exclusive" timeout="30">
>
> Would this work and can anyone think of any reasons NOT to do this?

Yes, it'll work. I'd probably create the name as a variable once per
request, just to avoid doing it in every CFLOCK tag. Or better yet,
since you mention storing the domain-specific info in the Application
scope, store this there as well.

Dave Watts, CTO, Fig Leaf Software
http://www.figleaf.com/

Fig Leaf Software provides the highest caliber vendor-authorized
instruction at our training centers in Washington DC, Atlanta,
Chicago, Baltimore, Northern Virginia, or on-site at your location.
Visit http://training.figleaf.com/ for more information!

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:319055
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4

Reply via email to