![](https://img-blog.csdnimg.cn/20201014180756925.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
问题专栏
敲代码过程中出现的错误
#小学生
这个作者很懒,什么都没留下…
展开
-
Failed to configure a DataSource: ‘url‘ attribute is not specified and no embedded datasource
而DataSourceAutoConfiguration类使用了@Configuration注解向spring注入了dataSource bean,又因为项目(oss模块)中并没有关于dataSource相关的配置信息,所以当spring创建dataSource bean时因缺少相关的信息就会报错。spring boot 会默认加载org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration这个类,原创 2022-09-20 15:47:16 · 101 阅读 · 0 评论 -
springboot2启动时候报错Failed to configure a DataSource: ‘url‘ attribute is not specified and no embedded
在pom.xml中添加依赖<build> <!-- 如果不添加此节点mybatis的mapper.xml文件都会被漏掉。 --> <resources> <resource> <directory>src/main/java</directory> <includes> <include>**/*..原创 2022-04-06 11:02:15 · 46 阅读 · 0 评论 -
Intellij idea报错:Error : java 不支持发行版本5
报错如下:是因为项目在编译配置时使用的Java版本不对,需要检查一下Project Structure中的Java编译版本配置。以我的版本1.8为例:1、可以在Project Structure的project以及Modules的sources,把版本都换成1.8,settings中的Build–>Java Compiler中的Target ByteCode version中的版本换成1.8即可,但这创建个项目就需要调整,很麻烦,所以我在下面写了一个一劳永逸的办法,配置依赖即可。2、在pom.原创 2022-03-28 21:16:46 · 647 阅读 · 0 评论 -
IDEA中java文件出现小黄色的J
idea中Java文件出现黄色的J,重新部署文件即可1、打开项目的工程结构设置2、打开modules选择sources,点击右侧的×3、移除当前的文件4、带年纪➕ 添加之前的项目,文件就变成正常的了原创 2022-03-11 20:53:49 · 13132 阅读 · 0 评论 -
Application run failed,org.springframework.beans.factory.BeanNotOfRequiredTypeExceptionPostman 415st
1、springboot + vue运用时遇见的错误,自己总结一下方便自己以后翻找,如果是同样的报错的话,也可以给网友节省时间。报错信息的翻译是这个意思:创建名称为’userController’的bean时出错。注入资源依赖关系失败;嵌套的异常是org.springframework.beans.factory.BeanNotOfRequiredTypeException。命名为’userService’的Bean应该是’com.dragon.springboot.service.IUserServ原创 2022-03-11 16:57:25 · 1574 阅读 · 0 评论 -
Springboot使用idea编辑器进行数据校验(JSR-303)使用@Email注解爆红
1.在使用springboot数据校验过程中,@Email爆红,出现下面的情况2.解决办法在pom.xml中添加如下依赖<dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-validation</artifactId></dependency>3.导原创 2022-01-06 22:12:22 · 2864 阅读 · 3 评论 -
idea中使用yml连接数据库Access denied for user ‘root‘@‘localhost‘ (using password: YES)
1.在springboot框架中,我在学习过程中出现的数据库连接yaml问题在yml配置文件中,如果密码是单纯的数字的话,需要加上单引号。否则会报错:idea中yml连接数据库Access denied for user ‘root’@‘localhost’ (using password: YES)亲身体会,很是折磨,网上搜了一大堆来回改了半天。...原创 2022-01-22 15:26:07 · 1712 阅读 · 0 评论 -
使用swagger2出现的错误Failed to start bean ‘documentationPluginsBootstrapper‘; nested exception is java.lan
在springboot项目中使用swagger2出现的报错信息如下:Error starting ApplicationContext. To display the conditions report re-run your application with ‘debug’ enabled.2022-01-27 16:49:51.422 ERROR 2528 — [ main] o.s.boot.SpringApplication : Applicati原创 2022-01-27 17:06:58 · 863 阅读 · 0 评论 -
Java异常: “2 字节的 UTF-8 序列的字节 2 无效。“的解决方案
1.如果是springmvc项目中springmvc-servlet.xml报错,建议把springmvc-servlet.xml中所有的中文注释都删除就能运行了。如果想保留中文注释的话,可以运行之后再加上,会有缓存,就不会报错了2.如果不是上面的报错的原因,建议检查Tomcat安装目录下的server.xml文件中是否被改动,出现中文注释,把中文注释删掉即可...原创 2021-11-23 21:36:21 · 541 阅读 · 0 评论 -
idea安装vue插件,但没有Vue Component组件
1.先介绍一下idea安装vue插件的步骤2.如果在File–>new那里没有Vue Component组件的话,可以按照如下步骤做:如果中间有什么问题,可以留言,看到会回复的原创 2022-02-09 11:23:10 · 756 阅读 · 1 评论