Eclipse integrates Tomcat and configuration, and eclipse integrates tomcat

Source: Internet
Author: User

Eclipse integrates Tomcat and configuration, and eclipse integrates tomcat
1. In Eclipse integration, click Windows --> Preference --> Server --> RuntimeEnvironment to display the following interface. Click the Add button, select the tomcat version, check createNewLocalServer, and click next to install it in wizard mode.
2. Change the configuration (installation path, release path, etc.) because the integrated tomcat is hosted by eclipse, the default tomcat connection will be blocked by eclipse. When integrated tomcat runs, it is generally not accessible from the browser directly through localhost: 8080. For convenience, You need to modify the tomcat configuration in eclipse as follows:
After tomcat is integrated, Windows --> ShowViews --> Servers will display:

Double-click the server. The configuration dialog box is displayed:
When tomcat integration is installed, ServerLocation-related options can be modified and changed to the figure. Specifically, Tomcat installation and Deploy path are also the webapps path of tomcat. The Port configuration module is available on the right, which can be modified as needed. Generally, the default value is enough.
3. Automatic deployment

Select a JavaDynamicProject, right-click the project, and choose RunAs --> Run on Server. If the project is a new project and has never been automatically deployed by eclipse, the page jumps out:


Select Always use this server when running this project. Then click Next and select "which projects need to be automatically deployed ".
Then click finish to start tomcat for the first time.
After each startup, you only need to click Run on server. When the code changes, stop the server and click Run on Server again to re-automatically deploy and load the project. After the server is started, the eclipse browser automatically jumps out and displays the home page of the project. After the server is restarted, You need to refresh the page to view the updated content.

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.