The difference between apache and tomcat

藏色散人
Release: 2019-10-09 18:03:06
Original
20526 people have browsed it

The difference between apache and tomcat

The difference between apache and tomcat

Apache

Apache HTTP server It is a modular server that can run on almost all widely used computer platforms. It belongs to the application server. Apache supports many modules and has stable performance. Apache itself is a static parser, suitable for static HTML, pictures, etc., but it can support dynamic pages, etc. through extended scripts, modules, etc.

(Apche can support PHPcgiperl, but if you want to use Java, you need Tomcat to support it in the Apache background, and forward Java requests to Tomcat for processing by Apache.)

Disadvantages: The configuration is relatively complex, and its own Dynamic pages are not supported.

Tomcat:

Tomcat is an application (Java) server. It is just a Servlet (JSP is also translated into Servlet) container. It can be considered an extension of Apache, but it can Runs independently of Apache.

Comparison between Apache and Tomcat

Same points:

Both are developed by the Apache organization

Both Both have the function of HTTP service

Both are free

The difference:

Apache is specially used to provide HTTP service. and related configurations (such as virtual host, URL forwarding, etc.), and Tomcat is a JSP server developed by the Apache organization under the JSP and Servlet standards of Java EE.

Apache is a Web server environment program, It can be used as a web server by enabling it, but it will not work if it only supports static web pages such as (ASP, PHP, CGI, JSP) and other dynamic web pages. If you want to run JSP in the Apache environment, you need an interpreter to execute the JSP web page, and this JSP interpreter is Tomcat.

Apache: focuses on HTTPServer, Tomcat: focuses on Servlet engine. If run in Standalone mode, it is functionally equivalent to Apache and supports JSP, but it is not ideal for static web pages;

Apache It is a Web server, and Tomcat is an application (Java) server. It is just a Servlet (JSP is also translated into Servlet) container. It can be considered an extension of Apache, but it can run independently of Apache.

In actual use, Apache and Tomcat are often used together:

If the client requests a static page, only the Apache server is required to respond to the request.

If the client requests a dynamic page, the Tomcat server responds to the request.

Because JSP interprets code on the server side, such integration can reduce Tomcat's service overhead.

It can be understood that Tomcat is an extension of Apache.

The above is the detailed content of The difference between apache and tomcat. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!