Following the crud-ssm tutorial in Silicon Valley, insert the following bean tags when configuring the spring environment configuration file applicationcontext.xml,
<bean id="sqlSessionFactory" class="org.mybatis.spring.SqlSessionFactoryBean">
<property name="configLocation" value="classpath:mybatis-config"></property>
<property name="dataSource" ref="dataSource"></property>
<property name="mapperLocations" value="classpath:mappers/*.xml"></property>
</bean>
among
<property name="mapperLocations" value="classpath:mappers/*.xml"></property>
It will be red. You only need to create any. XML file under Resources/maps, but this will lead to Title errors
just enter the project name\target\xxx-1.0-snapshot\WEB-INF\classes\mappers and delete the.XML file created at that time
Read More:
- SpringBoot Access Clickhouse Error: org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name ‘jdbcConverter’ defined in class path resource [***.class]
- [Solved] swagger3 Error: org.springframework.context.ApplicationContextException: Failed to start bean ‘documentationPluginsBootstrapper’; nested exception is java.lang.NullPointerException
- [Solved] SpringBoot Project Start Error: No bean named ‘org.springframework.context.xxxxx.importRegistry‘ available
- [Solved] Springboot Error: org.apache.catalina.core.ContainerBase : A child container failed during start
- How to Solve Springmvc Error: org.springframework.web.servlet.DispatcherServlet
- [Solved] Bat starts springboot project error: ERROR org.springframework.boot.SpringApplication -Application run failed
- [Solved] Error reported: org.springframework.validation.BeanPropertyBindingResult
- [Solved] error c101008d: Failed to write the updated manifest to the resource of file
- org.springframework.beans.factory.BeanCreationException: Error creating bean with name ‘globalTransa
- [Solved] org.springframework.dao.InvalidDataAccessApiUsageException: Error attempting to get column ‘Sage‘ fr
- [Solved] org.springframework.beans.factory.BeanCreationException: Error creating bean with name ‘dataSource‘
- [Solved] springmvc:Error creating bean with name ‘org.springframework.cache.interceptor.CacheInterceptor
- Error when Struts2 started Tomcat: org.apache.catalina.core.StandardContext filterStart
- [Solved] Asp.Net Core IIS Error: HTTP Error 500.30 – ASP.NET Core app failed to start
- Bin File Programming Failed, could not find core in coresight setup, erase error
- Start error in maven web project java.lang.ClassNotFoundException: org.springframework.web.util.Log4jConfigListener
- [Solved] net core HTTP Error 500.31 – Failed to load ASP.NET Core runtime HTTP Error 500.30 – ASP.NET Core
- Ranger Install Error: [E] ranger_core_db_mysql.sql file import failed!
- [Solved] Kubernetes Error: failed to list *core.Secret: unable to transform key
- Failed to parse host mirrors.opencas.cn [How to Solve]