Tomcat source code parsing 1:eclipse importing Tomcat sources

Source: Internet
Author: User
Tags apache tomcat

This series of articles takes Apache Tomcat 6.0.41 as an example.

(1) Download Tomcat source code: Http://tomcat.apache.org/download-60.cgi,apache-tomcat-6.0.41-src.zip, unzip.

(2) Create a Java project in eclipse named: APACHE-TOMCAT-6.0.41-SRC


(3) Remove SRC from build path, then delete src and copy all apache-tomcat-6.0.41-src.zip files to Eclipse's APACHE-TOMCAT-6.0.41-SRC project, then add the Java and test folders to the build path under "Use as a source folder".


(4) In the project directory, add the folder Exlibs, place the required jar for compilation, add the jar to build Path, and add the JUnit Library.


(5) After successful compilation, find the Org.apache.catalina.startup.Bootstrap class, "Run as", "Java application"

At this time, if not an accident, will report a mistake:


This is due to the WebApps under the examples project error, the examples can be deleted directly.

The bootstrap is then re-run to start successfully.


Access: http://localhost:8080 in the browser to access Tomcat normally.



End

You can download the Eclipse project, which compiles successfully, directly here: http://download.csdn.net/detail/xuefeng0707/8177597






Tomcat source code parsing 1:eclipse importing Tomcat sources

Related Article

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.