1.idea在springboot启动时报错Cannot determine embedded database driver class for database type NONE
项目结构:
在gmall-user中的application.propertites中配置了数据库连接和驱动,在加入@SpringBootApplication(exclude={DataSourceAutoConfiguration.class,HibernateJpaAutoConfiguration.class})后,又出现Property ‘sqlSessionFactory’ or ‘sqlSessionTemplate’ are required的问题,最后的解决办法是在pom文件里加入以下依赖。
<dependency>
<groupId>com.h2database</groupId>
<artifactId>h2</artifactId>
<scope>runtime</scope>
</dependency>