JAVA.LANG.NOSUCHMETHODEXCEPTION:ORG.APACHE.CATALINA.DEPLOY.WEBXML Addservlet

Source: Internet
Author: User

Recently in learning WebSocket's knowledge, I found some routines from the Tomcat sample file, but copied the project to MyEclipse, and the exception was reported when I started Tomcat, because I introduced two jar packages into this project. Catalina.jar,tomcat-coyote.jar. This is the two jar package provided by Tomcat. This exception occurs when the project is deployed in Tomcat and should be the cause of the packet conflict. I searched from the Internet a lot of solutions, there are three kinds of main.

1. Remove the Catalina.jar package that you added under referenced Libraries , and then remove the deployment program under WebApp and redeploy.

2, in Tomacat context.xml add <loader delegate= "true"/>

3. Modify the deployment configuration of the package, right-click project-> properties-> myeclipse-> Web, deployment Modify Lib ... Policies Cancel the default cancel jars from build path


These three ways should correspond to different projects to use, I appear this exception using the first and the third do not solve the problem, and ultimately the second way is the simplest and easiest to achieve. But for the second way, because it is modifying the Tomcat configuration file, I do not know what will cause the exception later. Therefore, if you can use the first or the third way to solve, it is best not to use the second type. Or, when you actually deploy the program, modify the files that were modified in Tomcat back.

JAVA.LANG.NOSUCHMETHODEXCEPTION:ORG.APACHE.CATALINA.DEPLOY.WEBXML Addservlet

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.