I'm a java newbie and I have a question about RMI on Windows.
In COM on Windows, you can create an out of process server that exists
in it's own process and you can call methods on it. Does RMI work this
way? Can I instantiate remote objects of the same class and have each
instance reside in it's own process space?
Thanks,
Curt
> I'm a java newbie and I have a question about RMI on Windows.
>
> In COM on Windows, you can create an out of process server that exists
> in it's own process and you can call methods on it. Does RMI work this
> way? Can I instantiate remote objects of the same class and have each
> instance reside in it's own process space?
Using RMI you can instantiate remote objects and interact with them
independently to each other or to the services provided by you published or
main services. It's kind of like each remote object is its own server.
They all reside in the remote JVM that hosts them, so to the extent they
come from the same JVM they are in the same process space. However, your
client can connect to any number of objects from any locations (including
itself) without being concerned where the actual server is so there is no
need for the objects to be in the same JVM--you can distribute them as you
like. What are you trying to accomplish by having each object in a separate
process space?
Cheers,
Matt Humphrey matth@ivizNOSPAM.com http://www.iviz.com/
Curt Tabor - 17 May 2006 18:13 GMT
Thanks! That clears things up and confirms what I thought. I am writing
a vehicle diagnostic system that uses Win32 DLLs to run concurrent
tests and these DLLs must reside in different process spaces or they
cannot be used concurrently. Since the project requires Win32, it looks
like COM out-of-proc servers is the way to go.
Curt
dimitar - 18 May 2006 16:45 GMT
Fowr what it's worth, you can get out-of-process remote objects by using
RMI Activation. What you need to do is to register each instance in its
own ActivationGroup.
Dimitar