Problems encountered in SSH learning

Source: Internet
Author: User
Tags ssh

The following two error exceptions are often encountered during the course of learning SSH

1.Servlet action is not available

This exception is typically a configuration file error

can refer to Http://blog.csdn.net/yangshoubo/archive/2009/09/05/4523457.aspx

2.java.lang.nullpointerexception xxx.action.xxxAction.xxxx

This means that an action cannot be executed because the integrated hibernate is given to spring to handle, The first thing to look at is whether the path to the action in the Applicationcontext.xml file is consistent with the struts-config.xml, and whether the type is the type defined in spring, because it is also possible that the type is inconsistent.

Workaround:
(1). The type of the Struts-config.xml action must be org.springframework.web.struts.DelegatingActionProxy
(2). This property is not required to delete the Type property of the action.
(3). Add a controller to the Struts-config.xml
<controller>
<set-property property= "Processorclass"
Value= "Org.springframework.web.struts.DelegatingRequestProcessor"/>
</controller>

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.