Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
Config mode 0 and cached components
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  8 messages - Collapse all  -  Translate all to Translated (View all originals)
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
RobM  
View profile  
 More options Mar 21 2012, 1:20 pm
From: RobM <anime1...@gmail.com>
Date: Wed, 21 Mar 2012 10:20:18 -0700 (PDT)
Local: Wed, Mar 21 2012 1:20 pm
Subject: Config mode 0 and cached components

Hello, I'm using version 1.5 and trying to find a way to reload the cached
components in the various environments (ex. production) without having to
log into the application. I have considered upgrading and using the
dashboard, but there are security concerns about having the dashboard in
production, as it might be accessible from the outside and the password
option is hardcoded into the config file. Also, there is a web cluster in
place, meaning each time a release is made, someone would have to go in and
manually reload the components on each node in the cluster. Is there any
other way to manually reload the components without the user needing to log
in, and perhaps a way to schedule it nightly?

Thanks in advance,
Rob


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
RobM  
View profile  
 More options Mar 26 2012, 7:34 am
From: RobM <anime1...@gmail.com>
Date: Mon, 26 Mar 2012 04:34:26 -0700 (PDT)
Local: Mon, Mar 26 2012 7:34 am
Subject: Re: Config mode 0 and cached components

Was it something I said? Or is that not possible?


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Joe Bodell  
View profile  
 More options Mar 26 2012, 10:02 am
From: Joe Bodell <joe.bod...@gmail.com>
Date: Mon, 26 Mar 2012 09:02:04 -0500
Local: Mon, Mar 26 2012 10:02 am
Subject: Re: [Mach-II] Re: Config mode 0 and cached components

In the past (and present, actually) I've set up a flag in OnRequestStart()
that looks for a url param that no one would ever ever try passing in.....

<cfif param exists (and its value is good, etc)>
    <cfset structClear(application) />
    <cfset onApplicationStart() />
</cfif>

It's extremely dirty, and probably exerts a non-zero load on the server for
having to be checked on every request, but it's eminently usable and can
easily be scheduled (just point your scheduled task at a url and attach
?superSpecialParamBomb=momerath to it)...

--Joe

--
------------------------
Joe Bodell
joe.bod...@gmail.com
(c) 952-465-5096

 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Joe Bodell  
View profile  
 More options Mar 26 2012, 10:08 am
From: Joe Bodell <joe.bod...@gmail.com>
Date: Mon, 26 Mar 2012 09:08:05 -0500
Local: Mon, Mar 26 2012 10:08 am
Subject: Re: [Mach-II] Re: Config mode 0 and cached components

Just to clarify -- this is a nuclear option, and it obviously kills
everything that's stored in your application scope. I believe there is a
method somewhere in the framework for clearing only its object cache...but
the same approach could be used.

--
------------------------
Joe Bodell
joe.bod...@gmail.com
(c) 952-465-5096

 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
RobM  
View profile  
 More options Mar 26 2012, 10:18 am
From: RobM <anime1...@gmail.com>
Date: Mon, 26 Mar 2012 07:18:49 -0700 (PDT)
Local: Mon, Mar 26 2012 10:18 am
Subject: Re: [Mach-II] Re: Config mode 0 and cached components

Does it have to be OnRequestStart() or does doing it later cause the
request to not complete? If not, it could be made into an event call with
some validation instead of an arbitrary url param.


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Joe Bodell  
View profile  
 More options Mar 26 2012, 10:22 am
From: Joe Bodell <joe.bod...@gmail.com>
Date: Mon, 26 Mar 2012 09:22:37 -0500
Local: Mon, Mar 26 2012 10:22 am
Subject: Re: [Mach-II] Re: Config mode 0 and cached components

You could do it in onRequestEnd() or somewhere else in the request
sequence, or in an actual event call so it's not being checked on each and
every request, sure :) The main reason I do it this way right now is that
we have Mach-ii running within a larger legacy app, and we want to be able
to reload ORM/coldspring services from anywhere. So we could probably
create a procedural template to do the same thing....but hey, nuclear =
good. Or something.

But yes, more than one way to skin this particular cat. The key is knocking
out the current contents of the application scope and hitting
onApplicationStart(), which should reload the framework and cached
components, etc.

--Joe

--
------------------------
Joe Bodell
joe.bod...@gmail.com
(c) 952-465-5096

 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
RobM  
View profile  
 More options Mar 26 2012, 10:24 am
From: RobM <anime1...@gmail.com>
Date: Mon, 26 Mar 2012 07:24:19 -0700 (PDT)
Local: Mon, Mar 26 2012 10:24 am
Subject: Re: Config mode 0 and cached components

Am I right in guessing that most people let it load with the application
scope when config_mode = 0?


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Kurt Wiersma  
View profile  
 More options Mar 26 2012, 12:30 pm
From: Kurt Wiersma <kwier...@gmail.com>
Date: Mon, 26 Mar 2012 11:30:46 -0500
Local: Mon, Mar 26 2012 12:30 pm
Subject: Re: [Mach-II] Re: Config mode 0 and cached components
I usually use config mode = 0 or a special url var that set the config
mode to 1 for that request. I have my ant deployment script hit the
app with the special url var to trigger the reload once deploy is
done.

--Kurt


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »