Robert, let us know how that new build works with web modules.

Unfortunately, I don't have time to mess with it right now.


99 comments
Comment actions Permalink

Brad wrote:

How do you have only one module that is a web module? Do you start with a
regular mod, add a web, then remove regular?


No I create project as usual, I go in Settings | Paths. Remove the
module, then add a new module that is a web module with the same name.
it seems to overrite it.

R

0
Comment actions Permalink

Which is why I can't get my stuff to work. None of the settings saves.
Robert, that screenshot you attached looks like you marked a bunch of
directories as 'Web Roots'. Do those save after closing the project?

"Robert S. Sfeir" <robert@codepuccino.com> wrote in message
news:bsshrf$uj9$1@is.intellij.net...

Igor Kuralenok (JetBrains) wrote:

Ian Zabel wrote:

>
>> How do I mark a library for deployment?
>
>

Settings | Paths | Web Module tab Children Modules.

>

Yeah and it doesn't save :) Once it saves the settings we can use it :)

>

R



0
Comment actions Permalink

Brad wrote:

Which is why I can't get my stuff to work. None of the settings saves.
Robert, that screenshot you attached looks like you marked a bunch of
directories as 'Web Roots'. Do those save after closing the project?


YES! This is exactly how we're supposed to do it. Forget the whole
dependencies Child Settings stuff completely until they implement it.

Everything is working perfectly now.

I also figured out a neat little workaround for the web.xml location
problem. It seems that if I save the module (mesquite-web.iml) file in
the resources directory, at the same level as the web.xml, then it
recognizes my web.xml. So I've got that little issue licked there too.

R

0
Comment actions Permalink

Ok guys. I;ve confirmed that you can in fact share the content root
now, no more issues with that, hence you can setup multiple web apps
which are in the same content directory.

I've attached 2 images to show how you can set it up, one is more
complex than the other. Both show the directories are in the same location.

This stuff works great.

I hope I can help more people get it going, because it really isn't that
hard once you know what you have to do.

R



Attachment(s):
web-mod2.gif
web-mod1.gif
0
Comment actions Permalink

For some reasone my project doesn't save those settings.

"Robert S. Sfeir" <robert@codepuccino.com> wrote in message
news:bssjn9$7oe$1@is.intellij.net...

Brad wrote:

>

Which is why I can't get my stuff to work. None of the settings saves.
Robert, that screenshot you attached looks like you marked a bunch of
directories as 'Web Roots'. Do those save after closing the project?

>

YES! This is exactly how we're supposed to do it. Forget the whole
dependencies Child Settings stuff completely until they implement it.

>

Everything is working perfectly now.

>

I also figured out a neat little workaround for the web.xml location
problem. It seems that if I save the module (mesquite-web.iml) file in
the resources directory, at the same level as the web.xml, then it
recognizes my web.xml. So I've got that little issue licked there too.

>

R




0
Comment actions Permalink

This is all fine a dandy and I can get it to work too but it still doesn't
save after closing the project.

"Robert S. Sfeir" <robert@codepuccino.com> wrote in message
news:bssk57$9ep$1@is.intellij.net...

Ok guys. I;ve confirmed that you can in fact share the content root
now, no more issues with that, hence you can setup multiple web apps
which are in the same content directory.

>

I've attached 2 images to show how you can set it up, one is more
complex than the other. Both show the directories are in the same

location.
>

This stuff works great.

>

I hope I can help more people get it going, because it really isn't that
hard once you know what you have to do.

>

R

>


-


-








-


-







0
Comment actions Permalink

Brad, there must be something wrong with your project or something. I'm
getting this to work consistently now 100% of the time.

If you want, feel free to send me a stripped down version of your
project, and I will look at it.

If anyone wants to chat about it, find me on Instant Messenger under rsfeir.

Hope this helps. It does take a bit to figure out what's up and what's
down, but once you do, it will click and it's actually easier than the
way it was under 3.0.5... honest.

R

0
Comment actions Permalink

Here's my project. What IM client do you use?

"Robert S. Sfeir" <robert@codepuccino.com> wrote in message
news:bsslne$hq3$1@is.intellij.net...

Brad, there must be something wrong with your project or something. I'm
getting this to work consistently now 100% of the time.

>

If you want, feel free to send me a stripped down version of your
project, and I will look at it.

>

If anyone wants to chat about it, find me on Instant Messenger under

rsfeir.
>

Hope this helps. It does take a bit to figure out what's up and what's
down, but once you do, it will click and it's actually easier than the
way it was under 3.0.5... honest.

>

R








Attachment(s):
StrutsDemo.zip
New Picture.gif
0
Comment actions Permalink

IM: AOL Instant Messenger

R

0
Comment actions Permalink

There you go, all fixed.

Can't have WEB-INF at the root of your project, the project root is not
a web root. Think of the deployment location as the location where your
web server is. I created a webapp directory to expand the project in.
Should work as expected now. Even closing and opening project worked.
I've made the project and I can see that everything is setup right in
the webapp dir.

Folks can probably download both the old and new version and compare.

Hope this helps.

R



Attachment(s):
StrutsDemo.zip
0
Comment actions Permalink

I'm not aware of the multiple content roots being an issue anymore. have
you tried that under 1050?


You are right, it works now. Way cool. :)

Michael

0
Comment actions Permalink

That's closer, thanks much. But, for some reason the jsps under
/pages/layouts/ don't resolve the taglibs. All others do including the ones
under /pages and /intro/pages/layouts. Any ideas?

"Robert S. Sfeir" <robert@codepuccino.com> wrote in message
news:bssnh4$pqh$1@is.intellij.net...

There you go, all fixed.

>

Can't have WEB-INF at the root of your project, the project root is not
a web root. Think of the deployment location as the location where your
web server is. I created a webapp directory to expand the project in.
Should work as expected now. Even closing and opening project worked.
I've made the project and I can see that everything is setup right in
the webapp dir.

>

Folks can probably download both the old and new version and compare.

>

Hope this helps.

>

R

>


0
Comment actions Permalink

What if I WANT the project root to be the web root? I don't want to change
the structure of my projects to 'fit' IDEA.

BTW - Thanks for all of your help Robert. IntelliJ should be paying you!

"Robert S. Sfeir" <robert@codepuccino.com> wrote in message
news:bssnh4$pqh$1@is.intellij.net...

There you go, all fixed.

>

Can't have WEB-INF at the root of your project, the project root is not
a web root. Think of the deployment location as the location where your
web server is. I created a webapp directory to expand the project in.
Should work as expected now. Even closing and opening project worked.
I've made the project and I can see that everything is setup right in
the webapp dir.

>

Folks can probably download both the old and new version and compare.

>

Hope this helps.

>

R

>


0
Comment actions Permalink

Brad wrote:

That's closer, thanks much. But, for some reason the jsps under
/pages/layouts/ don't resolve the taglibs. All others do including the ones
under /pages and /intro/pages/layouts. Any ideas?


Check that I didn't screw up the relative path, other than that, I'm not
entirely sure. it's not a nested jsp thing, it works for me here.

:-\

R

0
Comment actions Permalink

Brad wrote:

What if I WANT the project root to be the web root? I don't want to change
the structure of my projects to 'fit' IDEA.


Well it's not really fitting idea, I think it's the most flexible
solution I've seen of any ide.

You might be able to set the whole webroot as your project root by
assiging the project root as a Web Module Root, and don't use exploded
or war file deployment.

So your project root would be setup as an app server would expect it to
be running, and the project root would be marked as the webroot with
relative path of /. That would make everything else underneath it part
of the webroot.

No reason that wouldn't work.

R


BTW - Thanks for all of your help Robert. IntelliJ should be paying you!


For tech support? :) Tech support is overrated ;)

Thanks, and you're welcome, it's my pleasure to help. Usually when I
really belive in a product, I want to evangelize as much as I can so
others can enjoy it as much as I do.

R

0
Comment actions Permalink

Brad wrote:

That's closer, thanks much. But, for some reason the jsps under
/pages/layouts/ don't resolve the taglibs. All others do including the ones
under /pages and /intro/pages/layouts. Any ideas?


I just saw this... your first path includes an extra / at the end. take
that out.

R

0
Comment actions Permalink

Besides that this setting isn't saved: If I mark a library for deployment I get a compile time error 'The system cannot find the file specified'. Any idea what's going wrong?

0
Comment actions Permalink

That's what I originally had and it didn't work.

"Robert S. Sfeir" <robert@codepuccino.com> wrote in message
news:bstihk$fp7$1@is.intellij.net...

Brad wrote:

>

What if I WANT the project root to be the web root? I don't want to

change

the structure of my projects to 'fit' IDEA.

>

Well it's not really fitting idea, I think it's the most flexible
solution I've seen of any ide.

>

You might be able to set the whole webroot as your project root by
assiging the project root as a Web Module Root, and don't use exploded
or war file deployment.

>

So your project root would be setup as an app server would expect it to
be running, and the project root would be marked as the webroot with
relative path of /. That would make everything else underneath it part
of the webroot.

>

No reason that wouldn't work.

>

R

>

>

BTW - Thanks for all of your help Robert. IntelliJ should be paying you!

>

For tech support? :) Tech support is overrated ;)

>

Thanks, and you're welcome, it's my pleasure to help. Usually when I
really belive in a product, I want to evangelize as much as I can so
others can enjoy it as much as I do.

>

R



0
Comment actions Permalink

Do you have the checkbox to create a WAR file enabled in the web module?
In this case it might be this one:

http://www.intellij.net/tracker/idea/viewSCR?publicId=22972

Martin Fuhrer wrote:

Besides that this setting isn't saved: If I mark a library for deployment I get a compile time error 'The system cannot find the file specified'. Any idea what's going wrong?

0
Comment actions Permalink

Yes, that's exactly the case. Thanks.

0
Comment actions Permalink

Patrick, could you please send me in your project so that we can see what's not working.
Or at least share with us your settings. Thanks

--
regards,
Alexey Kudravtsev
Software Developer
JetBrains, Inc
http://www.jetbrains.com
"Develop with pleasure!"


"Patrick Burleson" <pbur@yahoo.com> wrote in message news:32360808.1072798533342.JavaMail.itn@is.intellij.net...

I see how that's working and it's pretty nice, but my only problem with it is that the way I use ant to deploy is I just copy

everything from my webapp directory, which means I have web.xml in its rightful place under WEB-INF.
>

Although, after seeing that setup, I am going to make my current project just a web module with a java src dir. That's too cool.

>

Igor, is it a bug that IDEA expects the web.xml to be in the root of the project? And that it doesn't seem to save other locations

of web.xml?
>

Thanks,
Patrick

>


0
Comment actions Permalink

Martin Fuhrer wrote:

Besides that this setting isn't saved: If I mark a library for deployment I get a compile time error 'The system cannot find the file specified'. Any idea what's going wrong?


Martin, if you read the thread (and it's long so read comments by Igor),
you can't use deployment settings. Child settings don't set either,
they're not done yet, and might not be done for 4.0.

If you'd like post or send a stripped down version of your project and I
can set it up for you.

I guess this should be serious sign to JetBrains if we have to send each
other projects so we can fix them for each other :)

R

0
Comment actions Permalink

That was a typo in the post. Not actually in the settings.

"Robert S. Sfeir" <robert@codepuccino.com> wrote in message
news:bstiqt$fp7$4@is.intellij.net...

Brad wrote:

>

That's closer, thanks much. But, for some reason the jsps under
/pages/layouts/ don't resolve the taglibs. All others do including the

ones

under /pages and /intro/pages/layouts. Any ideas?

>

I just saw this... your first path includes an extra / at the end. take
that out.

>

R



0
Comment actions Permalink

Alexey,
I would be more than happy to. Although, the only things not working for me at the moment are the saving of the location of web.xml and compiling. The project (which jars) is 6.5 MB zipped. Would you like me to post it here or email it to you? If email, then I need your address.

Thanks,
Patrick

0
Comment actions Permalink

For what it's worth to everyone, I've setup a web app without deploying
it, the way 3.0.5 used to work, it doesn't take a lot of effort either,
about as much as 3.0.5. I've included a pic to show how to set that up.

The issue right now is that if you check off both the war and exploded
dir deployment, you get an error on run. So the workaround is to just
setup a webapp dir and deploy to that for now, until JetBrains fixes the
problem.

I've filed a bug with the following description:

While trying to setup a web app with no exploded dir, and no war file, I
tried to start the debugging process, and it popped up an error saying
that Exploded module not found for webapp.

The issue here is that sometimes folks want to setup a web module which
in itself is the exploded directory, and we don't want to copy all the
files to one location.

If I check off the exploded and war file J2EE deployment settings, I
expect IDEA to just assume that the web module itself is setup properly.

In that case, web.xml should be copied to the existing WEB-INF at the
root of the web module, if it's not already there, and the rest should
be left alone, and the web module should be considered the web root with
relative path of /.

Thanks
R



Attachment(s):
305-webmod.gif
0
Comment actions Permalink

I don't fully agree with you. A quote from one of Igor's posts:

+As a matter of fact I don't think it's reasonable to create a web root for /WEB-INF/lib because it is generated from libraries marked to be included in deployment. Marking libraries for deployment is the right
way because taglibs are resolved only in such libraries.+

And indeed it does work if you don't create a war file (and if you set the marks again every time...). It is marked as fixed in build 1056.

So currently I'm quite happy. I either create no war file or I create a web root for /WEB-INF/lib. Both ways work fine.

But there's still the problem of placing my JSPs under WEB-INF. If you take a look at the sample project I attach taglibs are resolved correctly in 'demo.jsp' but (at least here) not in 'error.jsp' which is in a subdirectory.



Attachment(s):
j2ee-taglib.zip
0
Comment actions Permalink

Martin Fuhrer wrote:

I don't fully agree with you. A quote from one of Igor's posts:

+As a matter of fact I don't think it's reasonable to create a web root for /WEB-INF/lib because it is generated from libraries marked to be included in deployment. Marking libraries for deployment is the right
way because taglibs are resolved only in such libraries.+


Yes but when you close the project and re open it, it doesn't save the
library deployment settings, so you have to keep resetting them, so to
me, right now, it's reasonable to setup a web root location for the
libraries to /WEB-INF/lib.

also no project attached with your message.

R

0
Comment actions Permalink

Martin Fuhrer wrote:

I don't fully agree with you. A quote from one of

Igor's posts:


+As a matter of fact I don't think it's

reasonable to create a web root for /WEB-INF/lib
because it is generated from libraries marked to be
included in deployment. Marking libraries for
deployment is the right

way because taglibs are resolved only in such

libraries.+

Yes but when you close the project and re open it, it
doesn't save the
library deployment settings, so you have to keep
resetting them, so to
me, right now, it's reasonable to setup a web root
location for the
libraries to /WEB-INF/lib.


I absolutely agree, that's what I'm doing now as a workaround while waiting for 1056 or later.

also no project attached with your message.


Strange, I see it there. I'll send it by mail, it's not that big.

0
Comment actions Permalink

Ok, fixed my compile issue by giving IDEA an exploded dir to copy to...although as Robert has pointed out in his bug report, this shouldn't be necessary.

0

Please sign in to leave a comment.