On Wed, 22 Aug 2001, Rakesh wrote:

> what would it take to make parts of the struts-config readable from a
> database ?
>

You would need to subclass ActionServlet and override the initMapping()
method (where struts-config.xml is actually parsed), and replace it with
appropriate functionality to configure the mappings (and so on) from your
database instead.

The rest of Struts does not care at all where these things were configured
from -- it only wants the collections that are made available as servlet
context attributes, so this is conceptually pretty straightforward -- just
iterate through rows in your database tables and configure objects like
ActionMapping instances, and call methods like addMapping() to register
them.

>
>  Rakesh Ayilliath
> (Software Engineer)
>

Craig McClanahan

Reply via email to