You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by Laszlo Papp <la...@epigenomics.com> on 2004/07/01 17:35:20 UTC
Clearly separated RMI Client and Server JARs
Hi all,
We have tried to compile and distibute a client/server architecture
based on RMI and had to face some difficulties which seem to be lying on
the basic concept of the Maven environment (namely that one project is
only able to produce and distribute one and only JAR file).
We have set up 2 Maven projects (one for the client, one for the
server), and wanted to build the 'client.jar' as independent from the
server as possible... It means:
if I have the RMI interface implementation class 'Impl.java' in the
server project I only want to have the belonging 'Interface.java' in the
client project.
But the problem is that in the client project I also need to have the
'_Stub.java' class generated by RMIC, but the 'Impl.java' which I need
to generate it (with 'ant.rmic' task) is in the server project.
If I move the 'Impl.java' class to the client side and make RMIC
generate the Stub there, I bring many implementation specific code to
the client side, thus I'm voilating the concept of client/server
architecture...
If I do not do that, I only have "dirty" ways to go ('ant.copy' tasks
between the projects) if I want to bring the Stub classes generated by
RMIC to the client project and eventually to the 'client.jar'...
Is there a clear solution for this kind of problematic ?
Thanx a lot.
Chao:
Laci
--
Laszlo Papp
Epigenomics AG www.epigenomics.com Kleine Präsidentenstr. 1.
+49-30-24345-0 10178 Berlin
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org
Re: Clearly separated RMI Client and Server JARs
Posted by Laszlo Papp <la...@epigenomics.com>.
Jason van Zyl wrote:
> On Thu, 2004-07-01 at 11:35, Laszlo Papp wrote:
>
>
>>Is there a clear solution for this kind of problematic ?
>
>
> This is actually one of the nastiest use cases we are trying to sort out
> at the moment. All RMI-based solutions do this sort of thing and we're
> definitely working on a solution. This violates maven's notion of one
> artifact per project but all RMI-like compilers make the main JAR and
> client stubs so we'll find something that works.
>
>
>>Thanx a lot.
>>
>>Chao:
>>
>> Laci
>
>
Hi,
Thanx for the answer... Let's hope for the best... :-) But it is
obviously strange from the RMI framework that one needs the
_implementation_ classes in order to compile an independent interface
for that...
I hope it'll once work. Good luck... :-)
Chao:
Laci
--
Laszlo Papp
Epigenomics AG www.epigenomics.com Kleine Präsidentenstr. 1.
+49-30-24345-0 10178 Berlin
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org
Re: Clearly separated RMI Client and Server JARs
Posted by Jason van Zyl <jv...@maven.org>.
On Thu, 2004-07-01 at 11:35, Laszlo Papp wrote:
>
> Is there a clear solution for this kind of problematic ?
This is actually one of the nastiest use cases we are trying to sort out
at the moment. All RMI-based solutions do this sort of thing and we're
definitely working on a solution. This violates maven's notion of one
artifact per project but all RMI-like compilers make the main JAR and
client stubs so we'll find something that works.
> Thanx a lot.
>
> Chao:
>
> Laci
--
jvz.
Jason van Zyl
jason@maven.org
http://maven.apache.org
happiness is like a butterfly: the more you chase it, the more it will
elude you, but if you turn your attention to other things, it will come
and sit softly on your shoulder ...
-- Thoreau
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org
Re: Clearly separated RMI Client and Server JARs
Posted by Laszlo Papp <la...@epigenomics.com>.
Mark Church wrote:
> What about a 3rd project that contains Impl.java? Both the client and
> server projects could then depend on this project.
>
> Mark Church
>
Hi,
It would look better but it would still violate the concept of the
preferred DAG (Directed Acyclic Graph) dependency graphs...
Between the server and the 3rd JAR there would be a cyclic dependency.
Chao:
Laci
--
Laszlo Papp
Epigenomics AG www.epigenomics.com Kleine Präsidentenstr. 1.
+49-30-24345-0 10178 Berlin
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org
Re: Clearly separated RMI Client and Server JARs
Posted by Mark Church <mc...@www.IN.gov>.
What about a 3rd project that contains Impl.java? Both the client and
server projects could then depend on this project.
Mark Church
Laszlo Papp wrote:
> Hi all,
>
>
> We have tried to compile and distibute a client/server
> architecture based on RMI and had to face some difficulties which seem
> to be lying on the basic concept of the Maven environment (namely that
> one project is only able to produce and distribute one and only JAR
> file).
>
> We have set up 2 Maven projects (one for the client, one for the
> server), and wanted to build the 'client.jar' as independent from the
> server as possible... It means:
>
> if I have the RMI interface implementation class 'Impl.java' in the
> server project I only want to have the belonging 'Interface.java' in
> the client project.
>
> But the problem is that in the client project I also need to have the
> '_Stub.java' class generated by RMIC, but the 'Impl.java' which I need
> to generate it (with 'ant.rmic' task) is in the server project.
>
> If I move the 'Impl.java' class to the client side and make RMIC
> generate the Stub there, I bring many implementation specific code to
> the client side, thus I'm voilating the concept of client/server
> architecture...
>
> If I do not do that, I only have "dirty" ways to go ('ant.copy' tasks
> between the projects) if I want to bring the Stub classes generated by
> RMIC to the client project and eventually to the 'client.jar'...
>
>
> Is there a clear solution for this kind of problematic ?
>
> Thanx a lot.
>
> Chao:
>
> Laci
>
>
--
**********************************************************************
CONFIDENTIALITY NOTICE:
This E-mail and any attachments are confidential. If you are not the
intended recipient, you do not have permission to disclose, copy,
distribute, or open any attachments. If you have received this E-mail
in error, please notify us immediately by returning it to the sender
and delete this copy from your system.
Thank you.
accessIndiana, MyLocal.IN.gov, CivicNet
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org
Re: Clearly separated RMI Client and Server JARs
Posted by Martin van den Bemt <ml...@mvdb.net>.
We use a seperate project for all objects that are common between the
client and server classes, which includes the rmi stub...
(which is a post goal to java:compile btw). Not too much classes in the
project though, but it works well. (the common.jar has no external
dependencies at all).
Mvgr,
Martin
On Thu, 2004-07-01 at 17:35, Laszlo Papp wrote:
> Hi all,
>
>
> We have tried to compile and distibute a client/server architecture
> based on RMI and had to face some difficulties which seem to be lying on
> the basic concept of the Maven environment (namely that one project is
> only able to produce and distribute one and only JAR file).
>
> We have set up 2 Maven projects (one for the client, one for the
> server), and wanted to build the 'client.jar' as independent from the
> server as possible... It means:
>
> if I have the RMI interface implementation class 'Impl.java' in the
> server project I only want to have the belonging 'Interface.java' in the
> client project.
>
> But the problem is that in the client project I also need to have the
> '_Stub.java' class generated by RMIC, but the 'Impl.java' which I need
> to generate it (with 'ant.rmic' task) is in the server project.
>
> If I move the 'Impl.java' class to the client side and make RMIC
> generate the Stub there, I bring many implementation specific code to
> the client side, thus I'm voilating the concept of client/server
> architecture...
>
> If I do not do that, I only have "dirty" ways to go ('ant.copy' tasks
> between the projects) if I want to bring the Stub classes generated by
> RMIC to the client project and eventually to the 'client.jar'...
>
>
> Is there a clear solution for this kind of problematic ?
>
> Thanx a lot.
>
> Chao:
>
> Laci
--
Mvgr,
Martin
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org