Thanks guys, I come to the conclusion that splitting the project as Maven
recommends is the easiest solution. I wanted to preserve the compatibility
with our scripts but it is not worth it.
Khiet.

-----Original Message-----
From: Thomas Van de Velde [mailto:[EMAIL PROTECTED] 
Sent: Thursday, May 05, 2005 3:43 PM
To: Maven Users List
Subject: Re: Two artifacts for one project


Khiet,
 If you really do not want to change your source folders to seperate the ejb

code from your library code, you'll have to play around with the following 
properties:
maven.ejb.includes
maven.ejb.excludes
maven.jar.excludes
maven.jar.includes
 But as Steve already mentioned, this is not the recommended approach to 
build an EJB or JAR. I'd seperate both, each with its own project.xml. You 
can then use a reactor if you decide to have both source folders in the same

project. But you could also create two seperate projects each with its own 
project.xml at the root. (which is something you are forced to do if you use

WSAD and want to continue to use its J2EE plugins)
 Did you take a look at the Genapp plugin? You can run it with the complex 
template for an example of the first option.
 Thomas

 On 5/5/05, Tran, Khiet <[EMAIL PROTECTED]> wrote: 
> 
> Yes, and following Thomas' recommendations, I opened ejb:install and 
> it
> uses
> artifact:install exactly as I do.
> The difference between ejb:ejb/ejb:ejb-client and our custom ant-task is
> that I need both artifacts into my ear. I cannot get both (ejb/jar) into 
> my
> ear through dependency, which is not needed for ejb:ejb produced artifact.
> 
> 
> -----Original Message-----
> From: dan tran [mailto:[EMAIL PROTECTED]
> Sent: Thursday, May 05, 2005 3:06 PM
> To: Maven Users List
> Subject: Re: Two artifacts for one project
> 
> Khiet, did you use custom ant tasks to build your jar and jeb?
> 
> -D
> 
> On 5/5/05, Steve Molloy <[EMAIL PROTECTED]> wrote:
> > Better yet, you should split your code in 2 projects, one for 
> > component, and one for EJB which depends on the first one.
> >
> > Steve
> >
> > On Thu, 2005-05-05 at 19:36 +0200, Thomas Van de Velde wrote:
> >
> > > You should call ejb:install and jar:install. artifact:install is a 
> > > lower-level goal that should not be used directly. When you call 
> > > ejb:install, your ejb will be installed in an ejbs folder. When 
> > > you call jar:install, your jar is copied to a jars folder. You can 
> > > now use them as a dependency by setting <type>ejb</type> or 
> > > <type>jar</type> (The latter can be left out as by default 
> > > dependencies resolve to "jar". Thomas On 5/5/05, Tran, Khiet 
> > > <[EMAIL PROTECTED]> wrote:
> > > >
> > > > Hi everyone,
> > > >
> > > > We have a legacy directory structure of components that I want 
> > > > to convert to maven. The context I have is that for some 
> > > > components (maven project), a custom ant-task generates two 
> > > > different jars for it. root/
> > > > |----component
> > > > project.xml
> > > > |----target/
> > > > |-----componentEjb-version.jar -----component-version.jar
> > > >
> > > > So for installing these into the repository, I am using the 
> > > > artifact:install goal with 2 different types: jar & ejb, which 
> > > > installs 2 separate jars into the local repository. But I cannot 
> > > > retrieve one of the two jar as
> both
> > > > uses
> > > > the same pom.
> > > >
> > > > My question is, is it possible for me to specify a different pom 
> > > > then the current one ${pom} when using the goal 
> > > > artifact:install? And if I am using the same pom for both 
> > > > artifacts of different types, how do I refer to both as 
> > > > dependencies. I've tried it but it does not work.
> > > >
> > > > Thanks, Khiet.
> > > >
> > > >
> >
> >
> 
> ---------------------------------------------------------------------
> 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]
> 
>

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

Reply via email to