Hey, 
First of all - many thanks for the details answer.

Now, some remarks:

1. To begin with - I didn't put this on jira because I'm not sure I really
have a bug here. I think I'm just not quite familiar with the Maven
methodology and technology. I have questions about HOW things should work,
and not a statement about them not working...
Anyway, in order to recreate the problem, and if someone would be that
willing to help (for which I would be grateful) - I can send my projects.

2. Project B can in fact be built with maven. I've mentioned at first that
when using the mvn:package goal, I get a WAR with the dependencies all
worked out (i.e the contents of project A appear in project B's WAR).
My main problem really seems to be in eclipse's way of deploying project B
to tomcat - it doesn't work out the WAR dependency this way, which compells
me to deploy the WAR manually.

3. The problem of two projects in the same workspace that I mentioned is
this: http://jira.codehaus.org/browse/MNGECLIPSE-597
It has been solved out and will be delivered in the 0.9.7 version, so it's
not really the focus of my post.

4. As far as having project A's classes during compile time - I understand
now that it's not maven's intentions to do that. Of course maven can't add
project A's WAR to the classpath, that's not what I meant. I thought maven
should be smart enough to take the WEB-INF/classes/ out of project A's WAR
and include them in project B's classpath. Apparently not, so I will just
stick to having those classes in a jar of their own and define another
dependency on that jar.

5. I could not quite understand what you said about manually changing a
project's configuration and about the common module jar.
My real situation is that I have an infrastructure project that offers both
classes and web resources (such as jsps) to other projects. That's why I
want those projects to be dependent on it as a WAR and not as a JAR (I want
them to get the classes and the web resources). That's why I tried to do the
whole project A and project B thing.
The issue is that while developing, I might want to change code or resources
in both the infrastructure project and one of the other projects that depend
on it. That's why I don't want the other projects to be Mavenly dependent on
the infrastructure's WAR (since this way I won't be able to change the
infrastructure project easily - I'd have to produce a new WAR after every
change). I want them to be dependent on it in an Eclipse manner (using 'Java
EE Module Dependencies'). I just don't understand how this can be combined
with Maven eventually. After all, maven is the one that compells me to
declare both infrastructure project and the depending projects as Web
Dynamic Modules in eclipse. This way, I can't have the depending on each
other in the eclipse manner I've mentioned before. 

And thanks again

-- 
View this message in context: 
http://www.nabble.com/Maven-%2B-Eclipse-%2B-Tomcat-%2B-war-dependencies-tp21240154p21242355.html
Sent from the Maven Eclipse - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email


Reply via email to