Difference between web server, web container and application server
Asked Answered
E

8

112

Please tell me the Difference between web server, web container and application server.

Errolerroll answered 2/10, 2012 at 12:7 Comment(3)
possible duplicate of Difference between an application server and a servlet container? and #936697Atalante
Thanks for reply..i went through those links and would like to ask you one thing. Can we say Tomcat is a Application serverErrolerroll
No, Tomcat is a Servlet Container.Atalante
J
69

Your question is similar to below:

What is the difference between application server and web server?

In Java: Web Container or Servlet Container or Servlet Engine : is used to manage the components like Servlets, JSP. It is a part of the web server.

Web Server or HTTP Server: A server which is capable of handling HTTP requests, sent by a client and respond back with a HTTP response.

Application Server or App Server: can handle all application operations between users and an organization's back end business applications or databases.It is frequently viewed as part of a three-tier application with: Presentation tier, logic tier,Data tier

Jay answered 2/10, 2012 at 12:13 Comment(4)
Thanks for reply..can we say Tomcat is a Application server.Errolerroll
Apache Tomcat is Servlet Engine and IBM - WebSphere Application Server is an example for Application ServerJay
Apache HTTPD is a web serverOfilia
Apache HTTPD is a web server, Apache Tomcat is a web container, which is in fact Apach HTTPD + a Servlet Engine. A Java application server with the previous configuration would be: Apache Tomcat + EJB container + APIs (JDBC, JNDI, JTA/JTS, JCA, JMX, JAAS, Java Mail, JMS). A web container runs only WARs, an application server runs EARs.Rokach
S
10

Web Server: It provides HTTP Request and HTTP response. It handles request from client only through HTTP protocol. It contains Web Container. Web Application mostly deployed on web Server. EX: Servlet JSP

Web Container: it maintains the life cycle for Servlet Object. Calls the service method for that servlet object. pass the HttpServletRequest and HttpServletResponse Object

Application Server: It holds big Enterprise application having big business logic. It is Heavy Weight or it holds Heavy weight Applications. Ex: EJB

Sewing answered 28/1, 2015 at 13:26 Comment(0)
C
8

A Web application runs within a Web container of a Web server. The Web container provides the runtime environment through components that provide naming context and life cycle management. Some Web servers may also provide additional services such as security and concurrency control. A Web server may work with an EJB server to provide some of those services. A Web server, however, does not need to be located on the same machine as an EJB server.

Web applications are composed of web components and other data such as HTML pages. Web components can be servlets, JSP pages created with the JavaServer Pages™ technology, web filters, and web event listeners. These components typically execute in a web server and may respond to HTTP requests from web clients. Servlets, JSP pages, and filters may be used to generate HTML pages that are an application’s user interface. They may also be used to generate XML or other format data that is consumed by other application components.

Source: http://www.service-architecture.com/articles/application-servers/j2ee_web_server_or_container.html

Chemise answered 31/12, 2012 at 5:23 Comment(0)
S
4

Web container also known as a Servlet container is the component of a web server that interacts with Java servlets. A web container is responsible for managing the lifecycle of servlets, mapping a URL to a particular servlet and ensuring that the URL requester has the correct access rights.

Sandpit answered 31/7, 2015 at 0:11 Comment(0)
M
3

Web Container + HTTP request handling = WebServer

Web Server + EJB + (Messaging + Transactions+ etc) = ApplicaitonServer

Mucin answered 8/2, 2020 at 15:26 Comment(0)
C
2

The main difference between the web containers and application server is that most web containers such as Apache Tomcat implements only basic JSR like Servlet, JSP, JSTL wheres Application servers implements the entire Java EE Specification. Every application server contains web container.

Conal answered 16/7, 2017 at 21:10 Comment(0)
D
-1

Web containers are responsible to provide the run time environment to web applications. It contains components that provide naming context and manages the life cycle of a web application. Web containers are a part of a web server and they generally processes the user request and send a static response.

Servlet containers are the one where JSP created components reside. They are basically responsible to provide dynamic content as per the user request. Basically, Web containers reply with a static content as per the user request, but Servlets can create the dynamic pages.

Dionne answered 17/4, 2018 at 10:6 Comment(0)
A
-1

The basic idea of Servlet container is using Java to dynamically generate the web page on the server side using Servlets and JSP. So servlet container is essentially a part of a web server that interacts with the servlets.

Amiamiable answered 23/4, 2018 at 5:9 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.