Hi,

You build 5 projects :)

Serioulsy, I usually separate projects like this one into many (maven)
submodules, starting just like he/you offered:

common
server
client

and all three submodules are embedded in one top-level project.

So, a maven project layout:

projectX
  Xcommon (ifaces, common VOs, etc)
    src
    xdoc
    pom.xml
  Xserver (server)
    src
    xdoc
    pom.xml (deps is Xcommon)
  Xclient (client)
    src
    xdoc
    pom.xml (deps is Xcommon)
  xdoc...
  etc...
  pom.xml

Let's suppose that all these POMs are producing JARs.

If you need EAR deployment from projectX, take another projectX-EAR
(even sourceless, or just with EJB descriptors in src) and let it depend
from XServer and it will make you EJB. If you also need WAR, make
another projectX-WAR (same as for EJB). Don't be afraid to divide and
conquer. :)

Even if it seems at first that there is no reason to cut the project in
so many small pieces, later you will discover that it is the right way
to go.

All my collegues that had bad dreams using maven (Maven1) was doing the
_same_ error: trying to build more than one artifact (JAR, WAR, EAR,
etc) from one POM. DO NOT DO IT :)


bye
~t~

Gerwin Brunner wrote:
> Can anybody give me some input on this?
>
> Thanks,
> Gerwin
>
> Begin forwarded message:
>
>> From: Gerwin Bruner <[EMAIL PROTECTED]>
>> Date: November 22, 2005 2:54:07 PM GMT+01:00
>> To: [email protected]
>> Subject: Design Question
>>
>> Hi,
>>
>> I've got a client/server app which is communicating via RMI.
>> The application is using the spring framework.
>>
>> The server offers the following services/interface:
>>
>> Agent register(String username);
>> void unregister(Agent agent);
>>
>>
>> What is the best way to move this app over to maven?
>>
>> Do I build 3 projects: Server / Client / Interface (with the POJO's
>> like Agent that get transfered)?
>>
>> Is this a valid thought? Any other suggestions how to address this?
>>
>> Thanks,
>> Gerwin
>
>


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

Reply via email to