Is there a way to get
Struts to reload the message resources files without restarting the server or the application?
The following solution was posted by Stefaan Huysentruyt in December of 2005:
Just subclass both PropertyMessageResources and PropertyMessageResourceFactory. Name them something like ReloadablePropertyMessageResources and ReloadablePropertyMessageResourcesFactory and configure them like this:
The sources:
ReloadablePropertyMessageResources.java
ReloadablePropertyMessageResourcesFactory.java
Just put some statement like this in an Action:
and voilĂ ...
Return to
StrutsFaq