美文网首页后台
SSH三个错误的解决方案

SSH三个错误的解决方案

作者: 赵镇 | 来源:发表于2017-02-06 10:39 被阅读28次

给大家提供两个SSH项目配置过程中出现的问题以及他们对应的解决方案希望对大家有帮助

无法初始化Action

Unable to instantiate Action, userAction, defined for 'userAction_login' in namespace '/'Error creating bean with name 'userAction': Injection of resource dependencies failed; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No matching bean of type [com.itheima.bos.service.IUserService] found for dependency: expected at least 1 bean which qualifies as autowire candidate for this dependency. Dependency annotations: {@javax.annotation.Resource(shareable=true, mappedName=, description=, name=, type=class java.lang.Object, authenticationType=CONTAINER)}

这个错误的起因是Service没有配置好或者配置错误,请仔细观察自己的Service配置。如果是注解配置方式,请观察自己是否错写了@Service配置

找不到staffAction_Login.Action

这个主要是因为后缀名的原因。不要将后缀名写成大写。应该是staffAction._Login.action

Could not execute JDBC batch update

这种错误多半是自己的hbm文件写得有问题。。仔细检查hbm文件与类文件和数据库之间的对应关系。。找到错误并修改

相关文章

网友评论

    本文标题:SSH三个错误的解决方案

    本文链接:https://www.haomeiwen.com/subject/kkvyittx.html