org.springframework.beans.factory.BeanCreationException
来源:互联网 发布:篮球队logo设计软件 编辑:程序博客网 时间:2024/06/06 19:21
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'userDao' defined in file [F:\apache-tomcat-7.0.65\webapps\SMVCSH2\WEB-INF\classes\config\springAnnotation-beans.xml]: Cannot resolve reference to bean 'sessionFactory' while setting bean property 'sessionFactory'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sessionFactory' defined in file [F:\apache-tomcat-7.0.65\webapps\SMVCSH2\WEB-INF\classes\config\springAnnotation-hibernate.xml]: Cannot resolve reference to bean 'dataSource' while setting bean property 'dataSource'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dataSource' defined in file [F:\apache-tomcat-7.0.65\webapps\SMVCSH2\WEB-INF\classes\config\springAnnotation-hibernate.xml]: Error setting property values; nested exception is org.springframework.beans.NotWritablePropertyException: Invalid property 'userName' of bean class [org.springframework.jdbc.datasource.DriverManagerDataSource]: Bean property 'userName' is not writable or has an invalid setter method. Did you mean 'username'?
这是因为
<!-- 配置数据源 -->
<bean id="dataSource" class="org.springframework.jdbc.datasource.DriverManagerDataSource"><property name="driverClassName" value="com.mysql.jdbc.Driver"/><property name="url" value="jdbc:mysql://localhost:3306/springmvc"/><property name="userName" value="root"/>这里应该小写<property name="password" value="541711153"/></bean>
0 0
- org.springframework.beans.factory.BeanCreationException
- org.springframework.beans.factory.BeanCreationException
- org.springframework.beans.factory.BeanCreationException
- org.springframework.beans.factory.BeanCreationException
- org.springframework.beans.factory.BeanCreationException
- org.springframework.beans.factory.BeanCreationException:
- org.springframework.beans.factory.BeanCreationException
- org.springframework.beans.factory.BeanCreationException
- org.springframework.beans.factory.BeanCreationException
- org.springframework.beans.factory.BeanCreationException
- org.springframework.beans.factory.BeanCreationException
- org.springframework.beans.factory.BeanCreationException
- org.springframework.beans.factory.BeanCreationException
- org.springframework.beans.factory.BeanCreationException
- org.springframework.beans.factory.BeanCreationException
- org.springframework.beans.factory.BeanCreationException
- org.springframework.beans.factory.BeanCreationException:
- org.springframework.beans.factory.BeanCreationException
- android获取文件的md5值遇到的问题
- oracle数据库修改字符集
- SQL Server中创建Oracle的链接服务器
- 常见的web错误
- Android Listview 滑动时置顶悬浮效果
- org.springframework.beans.factory.BeanCreationException
- linux 下apache服务器的详细配置
- Android5.X (四) : Material Design-动画效果
- 内联函数总结
- [leetcode] 257. Binary Tree Paths 解题报告
- 山东省第六届蓝桥杯 ///标题:加法变乘法//c/c++组
- Ehcache(03)——Ehcache中储存缓存的方式
- checkio-the most wanted letter
- SQL语句判断数据库、表、字段是否存在