Good example Jochem, I'm a bit surprised about how many people think that locking is unnecessary. The need to do it is definitely less noticeable nowadays because your server won't crash, but it's still essential. Imagine charging your customer too little or too much because s/he was accessing your session scoped shopping cart with 2 browsers... not fun.
Locking is still required! (albeit in fewer cases) The solution of auto-locking in the CFAdmin is not optimal because, as Charlie Griefer mentioned, the performance impact could be catastrophic - especially if you were locking the application scope on every request! That would likely be your #1 bottleneck. It is in fact could practice to only use named locks. You should almost never lock an entire scope, except, perhaps, at app startup or some other rare case, but definitely not on every request. So this brings us back to the original question of how to manage all this. It would be nice to be able to encapsulate all locking somehow, and not have the developer worry about which variable was in what scope, and what's that lock name again? The developer would only reference the new custom scope called AppName (a CFC), that manages and contains all persistent vars. Oh, how that would be great... Baz ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Message: http://www.houseoffusion.com/lists.cfm/link=i:4:229380 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4 Donations & Support: http://www.houseoffusion.com/tiny.cfm/54