Is RMI Dead? Best architecture?

J

JavaEnquirer

I've been out of Java for a while and am bemused by the results I get
back when searching the groups for RMI answers. Most seem to be 4-5
years old or linked with weblogic or websphere. What are people using
these days? RMI?

I have an RMI server and 20 - 50 clients. The server makes call-backs
on the clients - which will be running 7 - 12 hours a day. However, I
am worried about timeouts and network failures and how the server will
be able to reconnect to any "lost" clients. ( Obviously, the server
won't be able to lookup the clients. ) I'm thinking of using RMI in
conjunction with sockets to ensure a robust/recoverable solution. Does
this make sense? Or, are people using newer techniques that are also
simple to configure. EJB seems to heavy weight for me.

Many thanks in advance.
 
J

Jerry Q

RMI is not dead. But of couse there are other protocols too.

I made a project a little bit like you descripted using Web Services.
I'm not not sure if it's suites for you but to be Web Servive Server and
Standalone Java Apps worked well.
 
P

Patrick May

JavaEnquirer said:
I've been out of Java for a while and am bemused by the results I
get back when searching the groups for RMI answers. Most seem to be
4-5 years old or linked with weblogic or websphere. What are people
using these days? RMI?

Under the covers, certainly.
I have an RMI server and 20 - 50 clients. The server makes
call-backs on the clients - which will be running 7 - 12 hours a
day. However, I am worried about timeouts and network failures and
how the server will be able to reconnect to any "lost" clients. (
Obviously, the server won't be able to lookup the clients. ) I'm
thinking of using RMI in conjunction with sockets to ensure a
robust/recoverable solution. Does this make sense? Or, are people
using newer techniques that are also simple to configure. EJB seems
to heavy weight for me.

Check out Jini (http://www.jini.org) for a lighter weight
architecture for distributed systems. Brian Murphy provides some
scripts (http://user-btmurphy.jini.org/) that make deployment
straightforward.

Regards,

Patrick
 
D

Daniel Dyer

I've been out of Java for a while and am bemused by the results I get
back when searching the groups for RMI answers. Most seem to be 4-5
years old or linked with weblogic or websphere. What are people using
these days? RMI?

They're all practising Service-Oriented Architectures (SOA),
Message-Oriented Middleware (MOM),Aspect-Oriented Programming and
Buzzword-Oriented Management.

RMI is still there, sometimes abstracted by something like Spring's
remoting framework, which makes it easier to switch between RMI, web
services and JSP.

Web services have replaced RMI for some applications, because the
technology is not so Java-centric, and JSP has replaced RMI for some other
things. The MOM approach with JSP reduces coupling and allows hosts to
communicate even if they are not available at the same time, with messages
being stored until they can be delivered.

I don't think too many people are using CORBA these days.

Dan.
 
R

rkm

Patrick said:
Check out Jini (http://www.jini.org) for a lighter weight
architecture for distributed systems. Brian Murphy provides some
scripts (http://user-btmurphy.jini.org/) that make deployment
straightforward.
check out the license terms before you proceed. I read a whole JINI
book and was about to take the plunge when I read the license terms and,
well I'm no lawyer, but it appeared to me my company could not deploy
the solution into our commercial setting without me getting the
corporate suits involved to strike an agreement with Sun. So I switched
to RMI just to avoid the whole question. This was two years ago, the
RMI stuff's been running great ever since. But like I said, I'm no
lawyer, maybe I misinterpreted what all that leagaleese was saying.

Rick
 
P

Patrick May

rkm said:
check out the license terms before you proceed. I read a whole JINI
book and was about to take the plunge when I read the license terms
and, well I'm no lawyer, but it appeared to me my company could not
deploy the solution into our commercial setting without me getting
the corporate suits involved to strike an agreement with Sun. So I
switched to RMI just to avoid the whole question. This was two
years ago, the RMI stuff's been running great ever since. But like
I said, I'm no lawyer, maybe I misinterpreted what all that
leagaleese was saying.

Jini 2.1 (the latest release) uses the Apache license. The
change was made in response to the Jini community raising exactly the
same concerns that you have here.

Regards,

Patrick
 
T

Thomas Weidenfeller

JavaEnquirer said:
I've been out of Java for a while and am bemused by the results I get
back when searching the groups for RMI answers. Most seem to be 4-5
years old or linked with weblogic or websphere. What are people using
these days? RMI?

Whatever they need. You are assuming that every application needs to do
some remote communication with other components using distributed
objects. Something which is probably not true at all for most
applications. The CORBA people seem to have made the same assumption
decades ago and are still surprised that not every application these
days is just a collection of distributed CORBA objects.

Being able to have distributed objects is a nice thing if you need this
feature, but needing it is a rare event. Therefore, all these remote
distributed object technologies are niche technologies.
I have an RMI server and 20 - 50 clients. The server makes call-backs
on the clients - which will be running 7 - 12 hours a day. However, I
am worried about timeouts and network failures and how the server will
be able to reconnect to any "lost" clients.

The server can't, unless you provide the server with a means to start-up
the remote clients again. Which is something one typically doesn't want.
You simply wait until the clients makes himself heard again. Then you
update the client with any information it might have missed.
( Obviously, the server
won't be able to lookup the clients. ) I'm thinking of using RMI in
conjunction with sockets to ensure a robust/recoverable solution.

I wouldn't throw in any extra communication. If you have a communication
line in between your objects it can go down any time. You have to deal
with that in your application architecture. It has to be able to live
with that. It doesn't help to throw more communication at the problem
(unless you go the expensive route and use truly redundant solutions,
not just yet another IP connection over the same non-redundant network).

This is not RMI-specific. Communication can fail in other technologies, too.

/Thomas
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,774
Messages
2,569,599
Members
45,169
Latest member
ArturoOlne
Top