Caused by: java.lang.IllegalArgumentException: The servlets named [ControllerServlet] and [com.classmgt.servlet.ControllerServlet] are both mapped to the url-pattern [/ControllerServlet] which is not permitted
It seems that you have mixed annotation-based
and web.xml-based
configuration.
I doubt that you created a Servlet using the "Create Servlet" wizard which creates web.xml entry with url-pattern and then , added a @WebServlet
annotation which duplicates anything you may put in the web.xml.
Read more: Servlet 3.0 Annotations
问题解答处
http://stackoverflow.com/questions/16270619/java-lang-illegalargumentexception-the-servlets-named-x-and-y-are-both-mapp/16277469