Hi,
I have a query regarding the ability of RPC servers to handle
multiple requests from clients concurrently. The CLIENT/SERVER
arrangement is as follows.
SERVER
------
I have set up an RPC server which simply registers the procedure "myproc"
to be called when a request is received for the given procedure/version
combination and then calls svc_run() (which waits for RPC requests to arrive
and calls the appropriate service procedure). eg
registerrpc(PROGNUM, VERSNUM, PROCNUM, myproc, xdr_void, xdr_u_long);
svc_run();
/* Should never return. */
CLIENT
------
I have an RPC client which calls the remote "myproc" procedure via the above
RPC server as follows:
callrpc(REMOTEHOSTNAME, PROGNUM, VERSNUM, PROCNUM,
xdr_void, 0, xdr_u_long, &result);
Once the server program is started on the remote host, running the client
program calls the procedure "myproc" on the remote machine and the result
is returned to the client as expected.
But if lots of client programs are calling the remote procedure "myproc"
simultaneously, these requests appear to be queued and processed serially one
after the other.
Is there a way of making svc_run() service the requests from the clients
concurrently instead of serially? i.e. I don't want a client to have to wait
for previous requests from other clients to be completed before its request
is executed.
Do I have to write my own asynchronous event handler to accomplish this?
Please E-mail any responses to me directly.
Thanks for any info,
Rob
--
.-_|\ Robert Coote Phone : +61 7 365 4321
/ \ CiTR Fax : +61 7 365 4399
\_.-._/ University of Queensland 4072