Spring Boot 错误 Failed to configure a DataSource: 'url' attribute is not specified and no embedde

***************************
APPLICATION FAILED TO START
***************************


Description:


Failed to configure a DataSource: 'url' attribute is not specified and no embedded datasource could be configured.


Reason: Failed to determine a suitable driver class

解决方法:

@SpringBootApplication(exclude = DataSourceAutoConfiguration.class

@SpringBootApplication(exclude = DataSourceAutoConfiguration.class)
public class StudentApplication {

   public static void main(String[] args) {
      SpringApplication.run(StudentApplication.class, args);
   }
}



猜你喜欢

转载自blog.csdn.net/weixin_42595573/article/details/80904172