maven-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Anders Hammar <and...@hammar.net>
Subject Re: One project per package or multiple packages in same project?
Date Tue, 18 Jan 2011 11:04:44 GMT
Have different projects for the different wars and then externalize any
configuration stuff outside of your wars.
We've been over this many times now. Here's one thread in the archive:
http://www.mail-archive.com/users@maven.apache.org/msg115082.html

/Anders

On Tue, Jan 18, 2011 at 11:17, Miguel Almeida <migueldealmeida@gmail.com>wrote:

> Hi,
>
> In
>
> http://maven.40175.n5.nabble.com/Maven-Problem-in-including-excluding-some-java-packages-in-the-src-while-creating-a-jar-td2641836.htmlAnders
> strongly discouraged having more than one package per project.
>
> However, I have a Maven conceptual doubt regarding this and thought you
> might be able to help.
>
> I have a webapp project in the format:
>
> -Parent
> ------ModuleServices
> ------ModulePersistence
> ------ModuleWeb
>
> Packaging the Parent returns what I am really interested in, the .WAR file
> returned from the ModuleWeb.
>
> However, I do need more than one WAR: two for the client (one with a test
> profile, with some test configuration strings like test-db and that returns
> a myproject-test.war; and another myproject.war which will be the
> production
> environment). Both will be installed on the same machine.
>
> Now, in addition to this, you also might see that these .war will be
> specific to a particular client (it's his db, his credentials..).
>
> Until I saw this post, I had different maven profiles (these 2 plus a
> development one) and my only doubt was "which profile will be active when I
> deploy the maven artifact?). Now it got me thinking: should I have one
> project per profile instead? Although I follow your logic, this approach
> seems cumbersome  and I'm not even sure how I'd implement it.
>
> Can you share your thoughts on how the best Maven approach would be?
>
> Thank you for your help,
>
> Miguel Almeida
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message