I've never tried this, but... is it as simple as calling
getServlet().init() in your Action?  getServlet() returns an instance of
the ActionServlet that is associated with the Action, and init() is
public, so...

Something though tells me this either (a) won't work at all or (b) is a
Very Bad Thing(tm) for one reason or another.

-- 
Frank W. Zammetti
Founder and Chief Software Architect
Omnytex Technologies
http://www.omnytex.com

On Thu, March 3, 2005 1:30 pm, Scott Purcell said:
> Thanks for the info Jerry,
>
> I get it ... but I am having trouble actually accomplishing this task.
> Since the ActionServlet is a "javax.http.servlet" I am not sure how to
> call its its init?
>
> The class is "org.apache.struts.action.ActionServlet" but I am uncertain
> how to init this thing?
>
> Anyone have any ideas?
>
> Thanks,
> Scott
>
>
>
> -----Original Message-----
> From: Jerry Tan [mailto:[EMAIL PROTECTED]
> Sent: Thursday, March 03, 2005 12:02 PM
> To: Struts Users Mailing List
> Subject: Re: Reloading Configuration File
>
>
>
> Scott,
>
> I haven't looked at that section lately, but I would imagine you can
> handle
> this by creating a separate action (e.g., ReloadAction) which just calls
> the init method of the ActionServlet.
>
> Whenever you'd like to reload the config file, then just go to the jsp
> that
> you've mapped for ReloadAction, and then that ought to do the trick.
>
> hth
>
>
>
>
>                       "Scott Purcell"
>                       <[EMAIL PROTECTED]        To:
> <user@struts.apache.org>
>                       nc.com>                  cc:       (bcc: Jerry
> Tan/DTCC)
>                                                Subject:  Reloading
> Configuration File
>                       03/03/2005 09:30
>                       AM
>                       Please respond to
>                       "Struts Users
>                       Mailing List"
>
>
>
>
>
> Hello,
>
> I was reading from my O'Reilly struts book last night, and it has a
> section
> on "Reloading The Configuration Files" pp 102. Because I am in
> development,
> I am constantly updating the config file and I have to keep stopping and
> starting my tomcat, I found the section interesting, but it gives no
> explanation on how to do this. It says one approach is to create a struts
> action that will reinitialize the ActionServlet?
>
> Does this mean I just need to recompile the ActionServlet that came with
> stuts, or do I need to subclass the ActionServlet and compile that. It
> looks like once you compile the ActionServlet, that it will reread the
> config?
>
> Does anyone have any knowledge in this area?
>
> Thanks,
>
>
> Scott K Purcell | Developer | VERTIS |
> 555 Washington Ave. 4th Floor | St. Louis, MO 63101 |
> 314.588.0720 Ext:1320 | [EMAIL PROTECTED] | http://www.vertisinc.com
> <
> http://www.vertisinc.com/>
>
> Vertis is the premier provider of targeted advertising, media, and
> marketing services that drive consumers to marketers more effectively.
>
>
>
>
>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to