This article is my record debugging Java program error, every encounter will update!
error 1. HTTP Status 405-http method GET is not supported by this URL
Workaround: Delete super.doget (request, response);
error 2.
HTTP Status 404-/simple/getaddress
--------------------------------------------------------------------------------
Type Status report
message/simple/getaddress
Description The requested resource (/simple/getaddress) is not available.
--------------------------------------------------------- -----------------------
apache tomcat/6.0.18
Workaround:
<welcome-file-list> <welcome-file>index.html</welcome-file> <welcome-file> index.htm</welcome-file> <welcome-file>index.jsp</welcome-file> <welcome-file> default.html</welcome-file> <welcome-file>default.htm</welcome-file> < Welcome-file>default.jsp</welcome-file> </welcome-file-list>
Don't delete the above code!
Another scenario is that the servlet path mapping error
<servlet> <servlet-name>cnServlet</servlet-name> <servlet-class> Tbexpcom.yto.servlet.commonservlet</servlet-class> <!--<load-on-startup>1</ Load-on-startup>- </servlet> <servlet-mapping> <servlet-name>cnservlet </servlet-name> <url-pattern>/servlet/CommonServlet</url-pattern> </ Servlet-mapping>
Continue to encounter problems, continue to solve the problem!
Java Program Debug Error set