Let's say you have a display TAG called DisplayOrder.cfm that accepts as an
argument OrderObj.cfc. Basically the TAG displays the contents of the CFC.

Let us also say that in 1 particular case you are passing an OrderObj that
is stored in the application scope to the TAG.

Where do you employ locking to avoid race conditions? It can't be within the
TAG because sometimes locking is not necessary. So do you lock the entire
call to the tag like so:

<cflock>
   <Order:Display OrderObj="#application.OrderObj#">
</cflock>

Does that even lock everything that happens within the tag and stop race
conditions? Isn't it extremely inefficient to lock a potentially huge chunk
of code when only a couple of lines really need to be locked? How do people
generally handle this?

Cheers,
Baz





~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Message: http://www.houseoffusion.com/lists.cfm/link=i:4:229873
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

Reply via email to