On Sep 19, 2005, at 10:23 PM, Miks Rozenbergs wrote:



Kristian Nordal <kristian.nordal <at> gmail.com> writes:




You need some way of connecting them together. If you don't have a
parent project, then they are just three independent projects. Then
you must put the dependencies in the repository manually. You should
look into creating a parent POM, <modules> are easy to use (and not a
lot of work) and things like dependency management is very nice.





Exactly -- connect them together. And IMHO defining dependancy from
"my.app.runtime" to "my.app.utils" is getting pretty close to connecting two
individuals together.



But where should it look for the other projects? Maven doesn't know that you have that project in another directory, next to the other project. If these artifacts are not in the same project, then the only "connection" is through the repository. So the dependency needs to be built in advance and put into the repository. Maybe it's possible to trigger a build in some way (this would then be from the repository or something like that, when a request is done), but I haven't heard of it.



So, creation of a parent project is duplication of
information.



I'm not sure of the inner workings of "modules", but I would guess that it looks for these modules/projects in the sub-directories, not in the repository. So this is another kind of "connection". This is not duplication of information, you are specifying where the project is located, not the built artifact.



And what if "my.app.utils" depends on something else? Then someone
should manually traverse all the dependancies and come up with a complete list
of modules to include in parent project.



I think you are mixing modules and dependencies. A dependency is fetched from the repository but modules are for defining recursive behavior in maven and relate projects (My understanding of it). Using modules, also implies (I think) defining the parent in the children POMs. This will enable Maven to generate a graph of this multi- project, so it's possible to trigger builds on dependencies in the project (since maven sees that they are connected / in the same multi- project, and know where to find the project).

These are just my impressions of how things work, so some of it (or all of it) might be wrong =)

--
Regards,
Kristian



Regards,
Miks



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]








---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to