0

I have a web application I'd like to edit while it's already deployed. The part I'd like to edit is inside ...applications/myapplication/WEB-INF/classes/META-INF/*.xhtml.

I have a tool that I use to generate these XHTML files and insert them into the aforementioned directory. In a production environment actually these XHTML files are part of a jar project included as a dependency in the main web application.

But what I need is to make hot deploy during development.

I can do it by removing the jar dependency and adding the XHTML in the directory mentioned above. But updating it later doesn't do the job.

Any idea?

Kukeltje
  • 12,223
  • 4
  • 24
  • 47
500 Server error
  • 644
  • 13
  • 28
  • I modified xhtml files in production environment with vim. Without changing the jar. If you have a command line on the production server it's no problem. Glassfish recognizes the change with the next access. – Holger Nov 15 '16 at 09:18
  • 1
    @Holger: Glassfish only recognizes changes IF JSF in your webapp is configured to reload. For production this is can be a delay. And it is never good to update pages inside your webapp. JSF is configurable to have e resource loader that loads pages from outside the war (e.g. a database or different filesystem). Better to use that. And for this there are duplicates in Stackoverflow – Kukeltje Nov 15 '16 at 09:26
  • @Kukeltje Thanks. – Holger Nov 15 '16 at 09:28
  • @Kukeltje How do I configure JSF to reload? – 500 Server error Nov 15 '16 at 09:47
  • 3
    normally by using google.... But I did that for you: http://stackoverflow.com/questions/7512414/jsf-and-automatic-reload-of-xhtml-files – Kukeltje Nov 15 '16 at 10:16
  • @Kukeltje Yeah I found that using Google. Thanks a ton. – 500 Server error Nov 15 '16 at 10:18

1 Answers1

0

If you're using IntellijIDEA, just go to the configuration of glassfish server and select "Update Resources" on "Frame Deactivation".