NPM : 17112805
Kelas : 4KA01
Exercise 2.11
Consider a
simple server that carries out client requests without accessing other servers.
Explain why it is generally not possible to set a limit on the time taken by
such a server to respond to a client request. What would need to be done to
make the server able to execute requests within a bounded time? Is this a
practical option?
Answer :
We cannot send a limit for the time taken by a server to respond a client request because the arrival of client requests is not predictable For example we can have limits for executing a computation corresponding to a request but we can not predict how much a request will have to wait until it's execution time arrives If the server uses threads there is not possible for the server to allocate sucient time to a particular request within any given time limit If the requests are carried out one at a time they may wait in the queue for an unlimited amount of time .
We can imagine the following solution trying to set a time limit in responding to client requests :
The practicability of our solutions :
- we can limit the number of clients to suit the server capacity to deal with many clients we should use a server with a higher capacity many processors .
- we can replicate the service
The practicability of our solutions :
- setting a limit for the number of clients that are able to suit the service we of er induces the lost of some client requests
- the introduction of replicas brings the problem of keeping them consistent . This requires also an amount of time that could be used for responding client requests
Tidak ada komentar:
Posting Komentar