In the document,I found some words like :
Restrictions on RMI
To avoid unnecessary complexity in the marking environment certain restrictions are placed on solutions that use RMI. Specifically:
You must not require the use of an HTTP server.
You must not require the installation of a security manager.
You must provide all classes pre-installed so that no dynamic class downloading occurs.
You must use RMI over JRMP (do not use IIOP)
Now I am confused.
Before running the Server,i must typed "start
rmiregistry" and direct the policy file.
how can i do if i want to use RMI ?
please help me !!!
You really don't need to do either of those. You don't need a policy file and you don't have to start the registry from the command line. You can start the registry inside your code with LocateRegistry.createRegistry() from withing your code.
From Sun's Fundamentals of RMI short course:
On top of TCP/IP, RMI uses a wire level protocol called Java Remote Method Protocol (JRMP). JRMP is a proprietary, stream-based protocol that is only partially specified is now in two versions. The first version was released with the JDK 1.1 version of RMI and required the use of Skeleton classes on the server. The second version was released with the Java 2 SDK. It has been optimized for performance and does not require skeleton classes. (Note that some alternate implementations, such as BEA Weblogic and NinjaRMI do not use JRMP, but instead use their own wire level protocol. ObjectSpace's Voyager does recognize JRMP and will interoperate with RMI at the wire level.) Some other changes with the Java 2 SDK are that RMI service interfaces are not required to extend from java.rmi.Remote and their service methods do not necessarily throw RemoteException.
Sun and IBM have jointly worked on the next version of RMI, called RMI-IIOP, which will be available with Java 2 SDK Version 1.3. The interesting thing about RMI-IIOP is that instead of using JRMP, it will use the Object Management Group (OMG) Internet Inter-ORB Protocol, IIOP, to communicate between clients and servers.
Long story short: If you use the RMI provided by Sun in the standard JDK, then you will be using JRMP. If you use another vendors RMI then you will fail on two counts: one for not using Sun standard APIs, and two for not using JRMP.
( and author)