Application server and web Server

There are two types of servers.

  1. Web server.
  2. Application server.

A Web server can be either a computer program or a computer running a program that is responsible for accepting HTTP requests from clients, serving back HTTP responses along with optional data contents, which usually are web pages such as HTML documents and linked objects on it. An application server is the kind of software engine that will deliver various applications to another device. It is the kind of computer found in an office or university network that allows everyone in the network to run software on the same machine.

Differences of Application server and web server.

  1. Web Server is designed to serve HTTP Content. App Server can also serve HTTP Content but is not limited to just HTTP. It can be provided other protocol support such as RMI/RPC.
  2. Web Server is mostly designed to serve static content, through most Web Servers have plugins to support scripting languages like Perl, PHP, ASP, JSP etc. through which these servers can generate dynamic HTTP content.
  3. In terms of the logical difference between web server and application server. web server is supposed to provide HTTP protocol level service while application server provides support to web service and expose business level service e.g. EJB.
  4. Web server is Supports Servlets and JSP.Application server supports the distributed transaction and EJB's.
  5. The Web Server does not support the concept of multi-threading. In Application Server, we have features like connection pooling, isolation pooling, multi-threading, and majorly the Transaction feature which is not there in Web Server.
  6. A web server has defined load limits, because it can handle only a limited number of concurrent client connections (usually between 2 and 60,000, by default between 500 and 1,000) per IP address (and IP port) and it can serve only a certain maximum number of requests per second. On the other hand, an application server has a much higher capacity.
  7. The application server is more capable of dynamic behavior than the web server. An application server can be configured to work as a web server.
  8. Web Server delegation model is simple when the request comes into the web server, it simply passes the request to the program best able to handle it (Server side program). It may not support transactions and database connection pooling.  Web servers support to deploy war files only while Application servers support to deploy .war and ear files.