I am working on a rather large JEE application that runs on WebSphere 8.5.5. Recently we switched our IDE from RAD to IntelliJ IDEA. Deployment on the server using the WebSphere plugin works mostly fine, but we have problems with the reload of changed resources like JSPs or XSLs.
Our project is a Gradle project, consisting of several modules, including one module containing the web app of our application. The project structure of our exploded artifact looks like this:
In the run configuration, the 'On Update' action is set to 'Update classes and resources'. Hot swapping changed classes works fine, but changed resources are not transfered to the server, which means that currently we have to redeploy the application for every change to a JSP. Does anyone have an idea how to fix this?
I also noticed some strange behaviour in this regard: When an editor window containing a resource file (JSP, XML config file ...) has focus, and I click on the update icon for the server (or press CTRL+F10), I get the message
Cannot package file
IO Error: java.io.IOException: Couldn't copy [D:\git\...\src\main\resources\XXX.xml] to [D:\git\...\build\libs\exploded\ABC.ear\XYZ.war\WEB-INF\classes\XXX.xml]
even when XXX.xml hasn't been changed. It's true that the path XYZ.war\WEB-INF\classes doesn't exist, because XYZ.war is a WAR file and not a directory, but why does IDEA try to copy the file there?