Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Wicket: Changes to HTML or Java Source is not loaded when browser is refreshed

I am following the Wicket user guide's "Hello World" project.

Wicket is in DEVELOPMENT mode.

When I change the HomePage.html and reload the browser, the change is not shown. If I restart the WicketApplication, then the changes are shown.

My application is at localhost 8080

All my research shows that changes should be loaded automatically when the application is in DEVELOPMENT mode (which it is).

I have not changed any configuration from the default Wicket installation.

like image 369
amortaza Avatar asked Sep 15 '25 23:09

amortaza


1 Answers

No, if you deploy your app into app-server (like tomcat, glassfish, etc.), then the real .html's that shows in browser located somewhere in app-server folders.

For glassfish it can be "/path_to_glassfish/glassfish/domains/domainXX/applications/APP_NAME/WEB-INF/classes/...". So, even if you change .html's at your project, you must to redeploy this changes.

Wicket JavaDoc says :

if the configuration type is DEVELOPMENT, resources are polled for changes...

Yes, but is holds for resources located at appropriate folders. I think this wicket forum thread will give you some answers of how to implements behavior you want. This post is actually for old wicket version, but I think it is suitable for newer versions too.

In our company we use firebug or chrome console to stylize components right in browser without redeploying app, and this is enough for us, because static components rarely added on the html page.

like image 157
Michael Zhavzharov Avatar answered Sep 17 '25 14:09

Michael Zhavzharov