Computer Systems: A Programmer's Perspective (3rd Edition)
Computer Systems: A Programmer's Perspective (3rd Edition)
3rd Edition
ISBN: 9780134092669
Author: Bryant, Randal E. Bryant, David R. O'Hallaron, David R., Randal E.; O'Hallaron, Bryant/O'hallaron
Publisher: PEARSON
bartleby

Concept explainers

Question
Book Icon
Chapter 12, Problem 12.23HW
Program Plan Intro

I/O Multiplexing:

  • The idea of I/O multiplexing is to use “select” function to ask kernel to suspend process.
  • It returns control to application only after one or more I/O events had occurred.
  • It denotes waiting for a set of descriptors that is ready for reading.
  • The “select” function would manipulate sets of type “fd_set”, that denotes descriptor sets.
  • It takes two inputs: a descriptor set called “read set” and cardinality of read set.
  • It blocks until at least one descriptor in read set is ready for reading.
  • A descriptor “k” is ready for reading if and only if a request to read 1 byte from that descriptor would not block.
  • The “fd_set” is been modified that points to argument “fdset” to indicate subset of read set called “ready set”.
  • The value returned by function indicates cardinality of ready set.

Blurred answer
Students have asked these similar questions
Computer Science C programming Develop a proxy HTTP server that can accept HTTP requests from clients and convert them to HTTPS request to the web server. The HTTP request can be filtered based on an access control list. The requests can be generated by any web client, such as the curl command or a web browser. the proxy converts plain text HTTP requests from a client to HTTPS requests and then returns the responses to the client. Main objective is to create a proxy HTTP server that converts cleartext HTTP requests from clients to HTTPS requests to servers and vice versa for the responsesresponses.
Currently, the web server handles only one HTTP request at a time. Implement a multithreaded server that is capable of serving multiple requests simultaneously. Using threading, first create a main thread in which your modified server listens for clients at a fixed port. When it receives a TCP connection request from a client, it will set up the TCP connection through another port and services the client request in a separate thread. There will be a separate TCP connection in a separate thread for each request/response pair.
Suppose an HTTP client makes a first GET request to the gaia.cs.umass.edu web server for a base page that it has never before requested, which contains an embedded object, which causes the client to make a second GET request. A very short time later, the client then makes a third GET request - for the same base page, with that third GET request having an  If-Modified-Since field (as does the 4th GET request that the client makes for the embedded object).  Neither the base object nor the jpeg object has changed. How many round trip times (RTTs) are needed from when the client first makes the third GET request (i.e., when it requests the base object for the second time) to when the base page and the jpeg file are displayed a second time, assuming that: any time needed by the server to transmit the base file, or the jpeg file into the server's link is (each) equal to 1/2 RTT the time needed to transmit an HTTP GET into the client's link is zero? the time needed by the server to transmit…
Knowledge Booster
Background pattern image
Computer Science
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
SEE MORE QUESTIONS
Recommended textbooks for you
Text book image
Database System Concepts
Computer Science
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:McGraw-Hill Education
Text book image
Starting Out with Python (4th Edition)
Computer Science
ISBN:9780134444321
Author:Tony Gaddis
Publisher:PEARSON
Text book image
Digital Fundamentals (11th Edition)
Computer Science
ISBN:9780132737968
Author:Thomas L. Floyd
Publisher:PEARSON
Text book image
C How to Program (8th Edition)
Computer Science
ISBN:9780133976892
Author:Paul J. Deitel, Harvey Deitel
Publisher:PEARSON
Text book image
Database Systems: Design, Implementation, & Manag...
Computer Science
ISBN:9781337627900
Author:Carlos Coronel, Steven Morris
Publisher:Cengage Learning
Text book image
Programmable Logic Controllers
Computer Science
ISBN:9780073373843
Author:Frank D. Petruzella
Publisher:McGraw-Hill Education