Web Module -- resolving jsp include directives (build 3242)

This problem has hit me twice now during Irida EAP.
It is really wierd. I upgrade and my jsp include
directies stop resolving the jsp files.

See attached pictures.
Our integration with IntelliJ is very simple. We don't use IntelliJ for building or deploying or web applications. All we want IntelliJ to do is to correctly resolve the include directives so that find usages and error hilighting works.

In my workspace I have web resources under

I setup the Web Module settings to that
Z:/65/web/html is mapped to /

I have a line in my jsp:
<%@ include file="/jsp/Global.jsp"%>

The actual file is Z:/65/web/html/jsp/Global.jsp

I checked back with IDEA 4.5.4 and the settings
look the same. In fact, I already went through
this once when I first upgraded to Irida EAP.
In that case, I had to recreate my Web module
to fix the problem. But that was in build 3200
or earlier. Now it is happening again with build 3242.

Is there anytime else I can try short of recreating
the Web module? I would really like to figure out
what is causing this problem, because it seems like
it will happen again if not fixed.

Comment actions Permalink

I recreated by web module, but it still isn't working.
See attached.

All I am trying to get is for my "/jsp/Global.jsp" and other jsp and javascripts files to be resolved properly.

But the "z:/65/web/html" mapped to "/" doesn't seem to work.

I think it would be nice if the Web Module setup wizard and the web module settings panel was simplified if you don't wnat IntelliJ to integrate with your Application Server.
Right now, we have this "Generic" server, but doesnt' anyone use this?

I would rather have a "None" setting, and then have the only thing displayed under Web Module Settings tab is a list of the resource path mappings like "z:/65/web/html" to "/".

I imagine there are lots of other people who use IDE-independent mechanisms, e.g. ant, to build and deploy to their application server, and would like it easier to setup the the minimum required to get "find usages" and error hilighting to work properly.

Comment actions Permalink

I am having exactly the same problem. I cannot use WebLogic integration due to the fact that Weblogic 6.1 is not supported for some strange reason. Simple JSP includes are not resolved no matter what I try.

Comment actions Permalink

The problem seems to be that you cannot have web resources that are inside the src directory.

Our dir structure is as follows:

project\src\com <-- java code
project\src\jsp <-- web resources

Comment actions Permalink

Instead of including the entire src directory, I was able to identify only the com directory as a source and append a package prefix (com) to the source folder. In the paths tab, under Source Folders, I now have "project\src\com (com)". Note the tiny "p" icon next to the X icon to the right of the source folder.

This prevents the source dir from overlapping my jsp directory, which seems to prevent includes from resolving.

Comment actions Permalink

Larry, thanks for your comments. It looks like the root of
the problem is Irida doesn't resolve JSP includes if the
jsps are withing a Source Folder.

I have two modules in my project.

"Server" module includes java code from Z:/65/web/java/
"Web" includes html/jsp/javascript/xml code from Z:/65/web/html

I don't have any overlap in the soures for the two modules.

But after reading your messages, I found out that the "Web"
module had the "." path listed as a Source Path. (see
attached file web_module_paths_not_working.gif)

After I Xed the "." source path, so that my "Web" module
only contained content, e.g. html / jsp / javascript / xml,
then all my JSP include directives resolved correctly. (see
attache file web_module_paths_fixed.gif)

I'll rechecked my project in IDEA 4.5.4, and my "Web"
module also had "." as a source path, but jsp includes
resolved correctly, so this behaviour in Irida is a
regression. I don't know if this change in behavior was
intended or it's just a bug. I'll file a JIRA issue on it.

Also, while I was looking at this, it struck me that the "
Source Folders" doesn't explicitly say it is only for Java
sources. I suggest that JetBrains explicity qualify it as "
Java Source Folders" now that they are adding support for
JSP, JavaScript, HTML, XML, etc. because those are 'sources'


Please sign in to leave a comment.