You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Gerwin Bruner <ge...@gmail.com> on 2005/11/22 14:54:07 UTC

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: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Fwd: Design Question

Posted by Cservenak Tamas <cs...@is-micro.hu>.
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 <ge...@gmail.com>
>> Date: November 22, 2005 2:54:07 PM GMT+01:00
>> To: users@maven.apache.org
>> 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
>
>



Fwd: Design Question

Posted by Gerwin Brunner <ge...@roodix.com>.
Can anybody give me some input on this?

Thanks,
Gerwin

Begin forwarded message:

> From: Gerwin Bruner <ge...@gmail.com>
> Date: November 22, 2005 2:54:07 PM GMT+01:00
> To: users@maven.apache.org
> 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