I don't think that will work.  Maven tends to get confused when one pom is
used to do multiple things, and you'd be trying to make a pom do both an ear
and a module build.  It's tricky to get the correct plugin to work in the
different lifecycles, and even worse to get a plugin NOT to work in certain
lifecycles.

One possiblity that did occur to me would be to use the antrun plugin and
use ant commands to create your ear by binding antrun to the package phase.
You'd lose the deployment capability though, and IMO it would be much less
maintainable.

On 6/27/07, Mick Knutson <[EMAIL PROTECTED]> wrote:

Can I do;

./pom.xml (EAR)
./war/pom.xml (WAR) (extends EAR pom)


On 6/27/07, Wayne Fay <[EMAIL PROTECTED]> wrote:
>
> That's how I build my J2EE projects, too. I usually have a couple
> /jarN and /ejb directories under there too.
>
> Wayne
>
> On 6/27/07, Thierry Lach <[EMAIL PROTECTED]> wrote:
> > I don't know if it would be a best practice, but I've been creating
> projects
> > that contains 3 poms...
> >
> > /pom.xml
> > /war/pom.xml
> > /ear/pom.xml
> >
> > First pom only references the other two poms as modules.
> > The entire project can be built from the first pom.
> >
> >
> > On 6/27/07, Mick Knutson <[EMAIL PROTECTED]> wrote:
> > >
> > > I have dozens of web services that are being created as WAR's. For
> > > consistency, each WAR that is deployed on seperate machines will be
> > > packaged
> > > as an EAR. Thus, each war also needed to be packaged into an EAR.
> > >
> > > Is there a better more "Best-Practices" way of doing this?
> > >
> > >
> > >
> > >
> > > On 6/27/07, Wayne Fay <[EMAIL PROTECTED]> wrote:
> > > >
> > > > Why?? While you might be able to configure this with some complex
> pom
> > > > file, I don't see the point when it is far easier (and actually
> > > > supported) to do this in 2 pom.xml files.
> > > >
> > > > Wayne
> > > >
> > > > On 6/27/07, Mick Knutson <[EMAIL PROTECTED]> wrote:
> > > > > I want to create a war and an ear in one module (pom.xml)
> > > > >
> > > > > --
> > > > > ---
> > > > > Thanks,
> > > > > Mick Knutson
> > > > >
> > > > > http://www.baselogic.com
> > > > > http://www.blincmagazine.com
> > > > > http://www.djmick.com
> > > > > http://www.myspace.com/mickknutson
> > > > > http://www.myspace.com/djmick_dot_com
> > > > > http://www.myspace.com/sexybeotches
> > > > > http://www.thumpradio.com
> > > > > ---
> > > > >
> > > >
> > > >
> ---------------------------------------------------------------------
> > > > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > > > For additional commands, e-mail: [EMAIL PROTECTED]
> > > >
> > > >
> > >
> > >
> > > --
> > > ---
> > > Thanks,
> > > Mick Knutson
> > >
> > > http://www.baselogic.com
> > > http://www.blincmagazine.com
> > > http://www.djmick.com
> > > http://www.myspace.com/mickknutson
> > > http://www.myspace.com/djmick_dot_com
> > > http://www.myspace.com/sexybeotches
> > > http://www.thumpradio.com
> > > ---
> > >
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


--
---
Thanks,
Mick Knutson

http://www.baselogic.com
http://www.blincmagazine.com
http://www.djmick.com
http://www.myspace.com/mickknutson
http://www.myspace.com/djmick_dot_com
http://www.myspace.com/sexybeotches
http://www.thumpradio.com
---

Reply via email to