Basic server model, Operating System

Suppose we want to program a Web server; we could easily do so without using concurrency, as follows:

while(true)
wait connection
read from socket and parse url
look up url contents in cache
if (!in cache)
fetch from disk
put in cache
send data to client

How do we make this codework for lots and lots of clients? Since there are a lot of slowoperations being performed (e.g. connecting to the networking, accessing the disk, etc), processing only one client at a time clearly is not scalable. Our goal then is to build a concurrent application that both minimizes latency and maximizes parallelism.

Posted Date: 3/13/2013 3:03:49 AM | Location : United States







Related Discussions:- Basic server model, Assignment Help, Ask Question on Basic server model, Get Answer, Expert's Help, Basic server model Discussions

Write discussion on Basic server model
Your posts are moderated
Related Questions
Process termination A process terminates when it finishes implementing its final statement and asks the operating system to delete it by using the exit system call. At that tim

What is graceful degradation? In multiprocessor systems, failure of single processor will not halt the system, but only slow it down by sharing the work of failure system by ot

Q. Error detection in operating system? Error detection- Error detection take places at both the hardware and software levels. At the hardware level every data transfers must b

What problems arise if the directory structure is a general graph? Searching for a particular file may result in searching the similar directory many times. Deletion of the fil

Q. Consider a calculating environment where a process is given the privilege of accessing object only n times. Suggest a scheme for implementing this policy. Answer: Add an i

Virtual File System serves two important functions. 1. It divides file-system-generic operations from their execution by defining a clean VFS interface. 2. The VFS is based

An operating system act as an intermediary between user of a computer and computer hardware. The objective of an operating system is to provide an environment in that a user can ex

LRU page replacement In slightest recently used page replacement algorithm we will replace that page that hasn't been used for the longest period of time. This is similar as an

When a program issues a memory load or store operation, the virtual addresses (VAs) used in those operations have to be translated into "real" physical memory addresses (PAs). This

The following is a dump of a TCP header in hexadecimal format: 00CD0018 00000EF1 00000D5D 502200D1 01BF0010 We need to first split the above hex as such 00 CD 00 18 00 00