Running the Example
Home ] Up ] ComputeEngineImpl ] Security Policies ] ComputePi ] ComputeEngineClient ] [ Running the Example ]

 

 

As before, in order to run the example, we have to do the following steps:

  1. Start the RMI registry by running the rmiregistry utility.
  2. Start the ComputeEngine server:

    On Windows:        start java rmiServer.ComputeEngineServer

    On Unix/Linux:        java rmiServer.ComputeEngineServer &

    If all goes well, the server should output:

    Setting SecurityManager ...
    Using port 2001
    Creating ComputeEngineImpl instance...
    [Re]binding ComputeEngineImpl instance in registry...
    Using url: rmi://localhost:2001/ComputeEngine
    Ready to compute...

    (Your port number may vary.)

  3. Run  the ComputeEngine client:

    java rmiClient.ComputeEngineClient

    If all goes well, the client should display:

    Using port 2001
    Locating remote ComputeEngine...
    Creating ComputePi instance...
    Requesting remote computation...
    Result: PI = 3.1415926535897932384626433832795028841972

Note: Again, the order in which we perform these steps is important!

 
The page was last updated February 19, 2008