The difference between Tomcat and Apache

Source: Internet
Author: User

1. Apache is a Web server, Tomcat is an application (Java) server, it is just a servlet container, is an Apache extension.

2. Apache and Tomcat can be run as standalone Web servers, but Apache cannot interpret Java programs (Jsp,serverlet).

3. Apache is an ordinary server, which itself only supports HTML as a normal Web page. However, PHP can be supported via plugins and can be connected to Tomcat (one-way Apache connection Tomcat, which means that Tomcat resources can be accessed through Apache.) otherwise)

4. Both are a kind of container, but publish something different: Apache is an HTML container, functions like IIS, Tomcat is a jsp/servlet container for publishing JSP and Java, similar to IBM Webshere, EBA WebLogic, Sun's JRun, etc.


5. Apache and Tomcat are independent and can be integrated on a single server.

An analogy: Apache is a truck that can hold something like HTML. But the water must be filled with containers (buckets), and Tomcat is a bucket (a water like Java), and the bucket can be kept out of the truck.

Apache only supports static Web pages, but dynamic Web pages like asp,php,cgi,jsp need to be handled by Tomcat.

Apache and Tomcat consolidated use: If the client is requesting a static page, only the Apache server responds to the request, or if the client requests a dynamic page, the Tomcat server responds to the request, because the JSP is the server-side interpretation code, This consolidation can reduce the service overhead of Tomcat.

Apache is the first Web server in the world to use. It can run on almost all of the widely used computer platforms


Apache originates from the NCSAHTTPD server and has been modified many times to become one of the most popular Web server software in the world. Apache is taken from the "a patchy server" pronunciation, meaning is full of patches of the server, because it is free software, so constantly someone to develop new features, new features, modify the original flaw. Apache is characterized by simple, fast, stable performance, and can be used as a proxy server. Apache support for Linux is quite perfect.

Apache has a variety of products that can support SSL technology and support multiple virtual hosts. Apache is a process-based structure that consumes more system overhead than threads, and is less suited to multiprocessor environments, so when you scale an Apache Web site, you typically increase the server or expand the cluster nodes instead of adding the processor. So far, Apache is still the most used Web server in the world, with a market share of about 60%. Many of the world's most famous websites such as Amazon.com, Yahoo!, W3 Consortium, Financial Times are the product of Apache, its success lies mainly in its source code open, there is an open development team, Supports cross-platform applications (which can run on almost all UNIX, Windows, Linux system platforms) and its portability.

The birth of Apache is very dramatic. When the NCSA WWW server project stalled, people who used the NCSA WWW server began exchanging patches for the server, and they quickly realized that it was necessary to set up a forum to manage these patches. In this way, the Apache group was born, and later the group created Apache on the basis of NCSA. If you are ready to choose a Web server, there is no doubt that Apache is your best choice.

Tomcat is a Java-based Web application container that is open source, running Servlets, and JSP Web application software. Tomcat server is executed according to the servlet and JSP specifications, so we can say that Tomcat server also implements the Apache-jakarta specification and is better than most commercial application servers.

Tomcat is a standard implementation of Java Servlet 2.2 and JavaServer Pages 1.1 technology and is a free software developed under the Apache license. Tomcat is a fully rewritten servlet API 2.2 and JSP 1.1 compatible servlet/jsp container. Tomcat uses some code from Jserv, especially the Apache service adapter. With the advent of the Catalina Servlet engine, the performance of the Tomcat fourth version has been improved, making it a worthwhile servlet/jsp container, so many Web servers are now using Tomcat.

**jsp=java Server Pages (Java Server Web page)
**asp=active Server Pages (Active Server Web page)
**cgi=common Gateway Interface (Universal Gateways Interface)
**j2ee=java 2 Platform, Enterprise Edition (JAVA2 Platform, Corporate Edition)
**xml=extensible Markup Language (extended Markup Language)
**iis=internet Information Server (Internet Information Server)

The difference between Tomcat and Apache

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.