Monday, 28 October 2013

CGI and Servlet

Http Protocol

Protocols works at two levels
  1. System level
  2. Application level
System level protocols will communicate the data between IP addresses. For example, TCP/IP or UDP (user Datagram protocol).
  • Application level protocols works on top of system level protocols. This application level protocol communicates from one application to other.
  • For example, http is an application level protocol which communicates a browser and a server application.
  • http protocol is also a stateless protocol. It means http protocol doesn’t remember a client data from one request to another request.
  • http protocol has multiple methods to transfer a request from a browser to a server but only two methods are important called get and post.
  • In some cases, get method will be use and some time post method will be used to send the request from a browser to a server.

Difference between CGI and Servlet technology

CGI and Servlet
NOTE: Even though the no. of clients are increasing, if an application performance is not decreased then such type of application is called scalable application.

What is the difference between Process model and Thread model?

In process model, for each request a new process begins at OS level but in thread model for each request a new thread begins server process begins. So process model increases burden on the server and thread model reduced burden on the server.

3 comments: