In myeclipse, how does one set the associated Tomcat server to hot start for a development website project? That is, when modifying the project source code, you do not need to restart Tomcat every time.

Source: Internet
Author: User

Currently, you are working on a website project using myeclipse + Tomcat. Every time you modify the project source code, you need to restart tomcat, re-export the project to the webapps folder, or redeploy it, which is too troublesome. So I studied how to set tomcat to a hot start, that is, the Tomcat server does not need to be restarted when the source code is modified. The method is as follows:

Step 1:

Modify CONF/server in the tomcat installation directory. in XML, set the reloadable attribute to true, that is, add reloadable = "true" to the host tag. Restart tomcat to make the configuration file take effect.

Step 2:

Add the following content to the Web. xml file in the conf Folder:

<Init-param>
<Param-Name> development </param-Name>
<Param-value> true </param-value>
</Init-param>

Step 3:

Restart the Tomcat server to make the modification take effect. Then, in the servers window of myeclipse, click the Red Circle button in the figure (deploy a new project to Tomcat ).

Then:

Click Finish. In this case, a prompt window may pop up, indicating whether to set it to automatically take effect every time the source code is modified. You don't have to restart it. Click OK.

 

OK, so far, the configuration is complete. After the source code (including servlet Code) is modified, you do not need to restart tomcat. However, you need to click the deployment button to redeploy the project.

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.