How well can JDK's LocateRegistry do in performance?

L

lightning

I've no idea of this server's performance, does somebody has
experience about that to share?
 
E

EJP

lightning said:
I've no idea of this server's performance, does somebody has
experience about that to share?

(a) java.rmi.registry.LocateRegistry is not a server.

(b) If you're asking about the performance of
java.rmi.registry.LocateRegistry.getRegistry() over the network, it
doesn't do anything over the network. It just constructs a local
Registry stub that refers to the host:port you specify. Only when you
*use* that stub will anything happen over the network.

(c) If you're asking something else, you need to clarify.
 
L

lightning

I ask about LocateRegistry.createRegistry(),it start a daemon thread
and lauched a server.
 
E

EJP

lightning said:
I ask about LocateRegistry.createRegistry(),it start a daemon thread
and lauched a server.

So none of that should take very long. What aspect of 'performance' are
you interested in?
 
L

lightning

So none of that should take very long. What aspect of 'performance' are
you interested in?

Thanks for your attention, the performance,for example: how many
requests it can handle and process correctly per second?
 
E

EJP

lightning said:
Thanks for your attention, the performance,for example: how many
requests it can handle and process correctly per second?

Same as any other RMI server. That's all it is. But I don't understand
why this would be a concern. The Registry isn't a bottleneck. You look
it up *once* in the lifetime of each client. Calls per second don't come
into it. Calls per day might.
 
L

lightning

Same as any other RMI server. That's all it is. But I don't understand
why this would be a concern. The Registry isn't a bottleneck. You look
it up *once* in the lifetime of each client. Calls per second don't come
into it. Calls per day might.

So we should keep the stubs storing in a singleton object and just
look up for them lazily, that's the best practice,right?
 
E

EJP

lightning said:
So we should keep the stubs storing in a singleton object and just
look up for them lazily, that's the best practice,right?

Exactly, or when you get NoSuchObjectException.
 

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

Forum statistics

Threads
473,768
Messages
2,569,574
Members
45,051
Latest member
CarleyMcCr

Latest Threads

Top