Solid Snake
Solid Snake

Reputation: 21

JSF2.0, How to load external resource bundle files?

I currently have my properties files put inside my project folder, so if I change the content of those files while my web app is deployed, the JSF pages that use these resource bundle won't be able to get updated automatically unless the server is restarted. This is quite troublesome when you only make small changes yet resulting the whole server to restart in order for it to be updated.

As I understand when the project is deployed, my JSF pages will refer to those properties files that are on the web server(Weblogic 11 in this case). But there is another thing, I am unable to find the deployment folder of Weblogic, therefore I cannot locate my WAR file.

Btw, I am using Eclipse Helios to deploy my project. Any help would be appreciated, many thanks in advance.

Upvotes: 2

Views: 984

Answers (1)

bogdan.mustiata
bogdan.mustiata

Reputation: 1845

The resource bundles are being cached by JSF in order not to hit the disk, so even if you would know the actual deployment path, you would still need to redeploy the whole web application.

For this reason I use jrebel (yes, it's a commercial product) that is actually able to change the resource bundle implementation itself, so it rereads the file whenever it changes.

Upvotes: 1

Related Questions