memory variables only timeout if they are not accessed the specified timeout
period.
every time anyone loads a page on your site, it accesses the application
scope and their session scope, so the timeout is reset back to 0.

An application will restart when ColdFusion restarts, when you reach the
applicationTimeout, if you force a restart via code or via the
CFADMIN/server monitor

When you say you use cgi.server_name to determine which variables to use,
are you being VERY explicity, as in the SERVER_NAME must match EXACTLY, or
are you doing an if/else to say if its this then set as live else set as dev
?



On Mon, Mar 28, 2011 at 6:25 PM, Dave Burns <[email protected]> wrote:

>
> In Application.cfc, I know that OnApplicationStart is called when an
> application starts. I'd like to define that better. From what I've read,
> this is when the first page is requested from an app (also possible are
> event gateways and Flash remoting but I'm not using either). So, if I say:
>
> this.applicationTimeout = CreateTimeSpan(1, 0, 0, 0);
>
> in my Application.cfc and a day goes by since calling OnApplicationStart,
> isn't it true that the server doesn't invoke my code on its own (like a cron
> job). It waits for a day to go by and then invokes OnApplicationStart on the
> next page request - even if that request is hours later?
>
> I'm asking because I'm trying to track down some odd behavior in a
> customer's app. The OnApplicationStart code looks at CGI.SERVER_NAME to
> determine which config file to load (production, staging, dev, etc.). Twice
> in the last 6 months, the production system starts to think it's a dev
> system. Are there cases where CGI.SERVER_NAME could be empty or undefined
> or... when OnApplicationStart is called? Can I trust that CGI var's are
> always set correctly in this scenario?
>
>
>
> 

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:343353
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm

Reply via email to