I migrated my project to IntelliJ 14 IDEA from STS 3.6.3 as STS keeping crash with not really clear exception.
I can configure IntelliJ to make my project works, but when I tried to modify my resources bundle property files to add some lines in that file to help my JSP to generate content, I found my IntelliJ not refresh when I build my project and deploy it on Tomcat server.
My project's Spring MVC (Web layer) original generated by using MyEclipse CRUD that came with SiteMesh and spring-dojo support. All web page (JSP) contents were put in resources bundle property file to support page content customisation.
When I migrate the project to IntelliJ, the original resources bundle was brought over, and I can see it siting in my "/$MODULE_DIR$/resources/bundles"
file name as "firm entity-resources.properties"
I can edit it and Synchronise it. I added some lines like:
firmentity.person.title.options=Mr.,Ms.,Mrs.,Dr.,Other
firmentity.firmstatus.options=New,Engaged,OutServiced
I can call by using
<fmt:setBundle basename="bundles.firmentity-resources"/>
<fmt:message key="firmentity.person.title.options" var="title_t" scope="session" />
<fmt:message key="firmentity.firmstatus.options" var="firmstatus_t" scope="session" />
in my JSP. and then retrieve it by using
<fmt:message key="firmentity.title"/>
this is very common usage in JSP.
I tried set it up in my OzsscWeb.iml with some very little modify to support dojo, but I never make my resources bundle refresh, very time I save my editing and redeploy my application to server, IntelliJ always take my original property file when I first migrated it from STS with out any newly edited content refreshing.
I totally lost my direction to my next step. Any one have such experience pleas help!!!
Any advice and suggestion welcome. With Plenty appreciation.
Have a happy Chinese New Year! Guys.
Edit
It is always siting in my "Sources Folders" in my "Project structure" Modules setting. I tried put it in my "Resources Folders" in my Modules setting, and press "Apply" and "OK" to make it works. But unfortunately, Every time I re-open my "Project Structure", it sit back to my "Sources Folders" again. I believe where is some thing mis-configured to it not work well.
This my IntelliJ config file OzsscWeb.iml. web-facet looks like:
<facet type="web" name="Web">
<configuration>
<descriptors>
<deploymentDescriptor name="web.xml" url="file://$MODULE_DIR$/WebContent/WEB-INF/web.xml" />
</descriptors>
<webroots>
<root url="file://$MODULE_DIR$/WebContent" relative="/" />
</webroots>
<sourceRoots>
<root url="file://$MODULE_DIR$/src" />
<root url="file://$MODULE_DIR$/generated" />
<root url="file://$MODULE_DIR$/resources" />
</sourceRoots>
</configuration>
</facet>
And there is some thing linked to it as:
<component name="NewModuleRootManager" LANGUAGE_LEVEL="JDK_1_8" inherit-compiler-output="false">
<output url="file://$MODULE_DIR$/target/classes" />
<output-test url="file://$MODULE_DIR$/target/test-classes" />
<content url="file://$MODULE_DIR$">
<sourceFolder url="file://$MODULE_DIR$/resources" type="java-resource" />
<sourceFolder url="file://$MODULE_DIR$/src" isTestSource="false" />
<excludeFolder url="file://$MODULE_DIR$/target" />
</content>
<orderEntry type="inheritedJdk" />
<orderEntry type="sourceFolder" forTests="false" />
</component>
It was specified as "java-resource". I tried to change it to some thing else, but seems it not work.
Edit
It is not a Java EE project, it is pure Spring MVC project, but it will call EJB client in @controller by using EJB injection (was defined as java bean). EJBs was deployed in WebLogic 12C server (runs in separate machine) with remote interface.
It sounds like the resources
folder is not being included in the module's sources list. Right-click on the project and select "Open Module Settings". In the "Modules" section, select the module in question and verify that the resources
folder is listed on the right. If it is not, select the folder in the left pane and click on the "Resources" button above.