JSP operating principle

Source: Internet
Author: User

When a JSP page on the server is executed on the first request, the JSP engine on the server translates the JSP paging file into a Java file, compiles the Java file into a bytecode file, and then responds to the client's request by executing the bytecode file. When the JSP page is requested to execute again, the JSP engine executes the bytecode file directly to respond to the customer. This is also a reason for JSP faster than ASP. The first execution of a JSP page is often performed by the Server Manager, and the main work of this bytecode file is:

The normal HTML markup symbol (the static part of the page) in the JSP page is given to the client's browser for display

Execute the Java patch between "<%" and "%>" (the dynamic part of the JSP page) and give the execution result to the client's browser for display.

When multiple customers request a JSP page, the JSP engine initiates a thread for each client instead of starting a process, which is managed by the JSP engine server and is much more efficient than the traditional CGI-initiated process for each client.

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.