DIRECTORY IO, Rope, RPC; ComputeServerClient: CEDAR DEFINITIONS = BEGIN ROPE: TYPE = Rope.ROPE; RemoteSuccess: TYPE = {true, false, timeOut, commandNotFound, aborted, communicationFailure, cantImportController, cantImportServer, serverTooBusy, clientNotRunning}; StartServiceProc: TYPE = PROC [service: ROPE, version: ROPE _ NIL, cmdLine: ROPE, in, out: IO.STREAM, queueService: BOOL _ FALSE, timeToWait: INT _ 3600, retries: NAT _ 3] RETURNS [found: BOOL, success: RemoteSuccess, remoteMsg: ROPE, serverInstance: ROPE]; StartService: StartServiceProc ; BestServerStatsProc: TYPE = PROC RETURNS[success: RemoteSuccess, selfIsBest: BOOL, FOM: REAL]; BestServerStats: BestServerStatsProc ; RegisterProcs: PRIVATE PROC [StartService: StartServiceProc, BestServerStats: BestServerStatsProc ] ; END. NComputeServerClient.mesa The Compute Server Client interface. This interface is between the Client (the rest of the Cedar world) and the Client code for the Summoner on the workstation, and thus is not an RPC interface. Last Edited by: Bob Hagmann, May 15, 1985 1:00:21 pm PDT Copyright c 1985 by Xerox Corporation. All rights reserved. These values mean - true: the command succeeded false: various errors may have occurred: protocol errors in session establishment between the client and the server (see "remoteMsg" if available from the call) timeOut: a queued request timed out aborted: the "aborted" signal has been raised remotely. One way to do this for typical commands is to click "STOP!" in the command tool running the client interface. communicationFailure: this occurs when the pup byte stream fails, or the "callbacks" via RPC to the client workstation ceases to work, cantImportController: the machine identified by grapevine as the controller would not establish the RPC calls. cantImportServer: the server selected by the controller would not establish the RPC calls. serverTooBusy: the server selected by the controller was too busy, running an exclusive command, or already running too many of the selected command to start a new command. The client might try again, give up, or wait and try again. clientNotRunning: the client on the workstation has not been run. Attempt to start the command named "service". If "version" is specified, only this version of the software will be used. "cmdLine" is a ROPE that will be given to the command. If "in" and/or "out" are specified and non-NIL, a pup byte stream is created and given to the command on the server. This stream is buffered and bytes are delivered or accepted from "in" and/or "out" as appropriate. "queueService" requests the Controller to do queueing and find a server that will handle the request. The request will be queued by the Controller for "timeToWait" seconds or until it is accepted by a server. If FALSE, the Controller selects a server, but the Client's machine is responsible for contacting the server and asking for the request to be handled. Any server may refuse such a request. "retries" is the number of times to retry to overcome (apparently) transient errors. If successful, "serverInstance" is the Pup Address expressed as a ROPE of the server that performed the command. Ask the controller which machine has the best figure of merit (FOM). FOM is in the range 0.0 to 1.0 with 0.0 being idle. FOM is left otherwise undefined. Registration - for internal Compute Server Use Register internal procedures  not for general use by clients. Bob Hagmann February 12, 1985 2:16:06 pm PST changes to: RemoteSuccess, ComputeClient Bob Hagmann May 6, 1985 8:00:51 am PDT update comments, add commandNotFound to RemoteSuccess, and add queueService and retries to StartService Κκ˜headšœ™IbodyšœΓ™ΓL™8Jšœ Οmœ1™<code2šΟk ˜ M˜Mšœ˜Mšžœ˜——šœžœž œ˜(Mšž˜Mšžœžœžœ˜šœžœ“˜¦šœ™Mšœ™šœ(™(Mšœw™w—Mšœ#™#Mšœ¦™¦Mšœ‡™‡Mšœn™nMšœZ™ZMšœι™ιMšœA™A——Mš"Πbnœžœžœ žœ žœžœ žœ žœžœžœžœžœžœžœ žœ%žœžœ˜šΟn œ˜ Mš œŠΟsœP‘œ‚‘œΟ‘œ*™εM™Icode™—Nš œžœžœžœ%žœžœžœ˜^N˜š œ˜'N™›N˜——™.N˜š  œž œK˜fN™>N˜—N˜Mšžœ˜—™,Nšœ Οr™(—™&Nšœh™h—Nš ™—…—$\