The scope I used would depend on the manner in which I was using the CFC.

Something used on every request, like a user.cfc or cfc for logging I 
would use the application scope, however if it's something thats used 
less often but needs to exist across multiple requests I would use 
session variables, if it only needs to exist for the life of the single 
request, I use the request scope.

Randy wrote:
> To those who use CFCs as Objects:
> 
> Is it best to create the CFC objects within the application or session scope
> to be called throughout the application?
> 
> Ex:
> 
> -- OnApplicationStart
> <cfscript>
> application.lookupCFC = createobject('component','cfcs.lookup');
>  </cfscript>
> 
> -- OnSessionStart
>  <cfscript>
> session.lookupCFC = createobject('component','cfcs.lookup');
>  </cfscript>
> 
> 
> 

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

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:313014
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