3vi
3vi

Reputation: 440

Hot-deploy Liferay 7 webapp resource (JavaScript/CSS/HTML)

I am developing a Liferay 7 portlet with bundled Tomcat 7.

To deploying a portlet, I copy the war file into deploy folder under Liferay home folder, and then I have to wait a lot of minutes to see my file modified.

Usually I work only on javascript, css and html, I want to see immediately what I changed, then, is there a way to have hot deploy for webapp resource?

Thanks

Upvotes: 2

Views: 701

Answers (2)

atrujillofalcon
atrujillofalcon

Reputation: 1052

Liferay cache all resources by default, because that you have to wait a lot of time to see the changes. You have 3 ways to force Liferay to delete this cache.

  1. Before deploy the module you must delete the module cache folder. This is in the following path (this applies to js and jsp resources):

liferay-ce-portal-7.0-ga3/work/your_module_name

  1. Delete the module cache servlet folder located in:

liferay-ce-portal-7.0-ga3/tomcat-8.0.32/work/Catalina/localhost/ROOT/css/http_/o /your_module_name

  1. The other option is enter in Liferay Control Panel and click the cache action tasks:

enter image description here

Upvotes: 0

Gaurav J.
Gaurav J.

Reputation: 231

You should use the Liferay workspaces and modules. If it is a theme, the gulp watch task will help.

Upvotes: 1

Related Questions