the dope on scope
I've done a bit of research on Cold fusion scopes, but i still am a bit confused. I'd really appreciate it if somebody corrected my assumptions outlined below.
Server scope is part of CF, it persist based on a setting in CF Admin and is only re-created by re-starting cold fusion at the server level. - based on it's name, it is tied to a single server in a cluster. so server.whatever is the same for anybody hitting the server.
Application scope is part of CF, it persists based on a setting in CF Admin and is re-created whenever the 'onApplicationStart' function is called in CF. it is less persistent than server but more persistent than session. It is also strongly tied to a single server in a cluster. This is a shared scope variable. Each different application run on a server has its own set of application variables, therefore this variable is less persistent than server. if i have two applications on my server, than i can easily have two different versions of application.whatever
Session Scope is a part of CF, it exists and persists based on a setting in the application.cfc. When J2EE sessions are used, it persists across servers in a cluster. Each session in an app can have it's own copy of the variable, therefore it is less persistent than an application variable.
Request Scope is a part of CF. It's the one i'm having the most trouble understanding ...based on its position in the application.cfc it is less persistent than application, however how many request variables are created? Are they created anew so that your request.whatever and my request.whatever can be different without a problem and thus less persistent than session? or is it instead more persistent than session but less than application. If i create an variable in request, and have say five users (each with one session) on my application page at a time, how many request variables couldi have?
Variables scope is a part of CF as well. any variable, structure, recordset or scope created outside of the above but inside of a page request will exist within variables. These definitely persist only from the start of a page or fuseaction call to the end of it. variables scope appears to be discarded between say, index.cfm and page1.cfm (in addition, if you and i both call index.cfm, we have two different sets of variables within variables scope where the system is concerned) on a particular site.
I am particularly interested in how exactly request and variables scope are actually different from each other. i noted that request does NOT appear when i dump variables, nor variables when i dump request
