A bean with that name has already been defined in DataSourceConfiguration$Hikari.class

构建springcloud的时候一定要注意起微服务的版本 不然会报上面的错误

原因:
SpringBoot和SpringCloud的版本不兼容造成。
这里因为SpringBoot想尝鲜使用了2.1.0,而SpringCloud仍然用的是Finchley.SR2,而它支持的是2.0.x及以下版本。
对应的版本应该使用Greenwich.M1。
Issues回答:

解决:
降SpringBoot版本或者使用Greenwich.M1。
所以还是建议直接在start.spring.io上构建新项目,或者在idea上构建项目的时候选择Spring Initializr来避免版本不兼容。
---------------------
作者:Orcas阿晨
来源:CSDN
原文:https://blog.csdn.net/u012211603/article/details/83714285
版权声明:本文为博主原创文章,转载请附上博文链接!

A bean with that name has already been defined in DataSourceConfiguration$Hikari.class的更多相关文章

  1. springboot 解决 The bean 'userRepository', defined in null, could not be registered. A bean with that name has already been defined in file XXX and overriding is disabled.

    1.springboot 启动时报错: 2019-02-20 14:59:58.226 INFO 10092 --- [ main] c.f.s.SpringbootssmApplication : ...

  2. A bean with that name has already been defined in class path resource [org/springframework/transaction/annotation/ProxyTransactionManagementConfiguration.class] and overriding is disabled

    2019-12-19 13:26:17.594 WARN [main] o.s.boot.web.servlet.context.AnnotationConfigServletWebServerApp ...

  3. Feign 报错:The bean 'service-producer.FeignClientSpecification', defined in null, could not be registered. A bean with that name has already been defined in null and overriding is disabled.

    报错: 2019-09-17 20:34:47.635 ERROR 59509 --- [ main] o.s.b.d.LoggingFailureAnalysisReporter : ******* ...

  4. SpringBoot启动报错:ould not be registered. A bean with that name has already been defined in file and overriding is disabled.

    SpringBoot启动报错 ***************************APPLICATION FAILED TO START*************************** Des ...

  5. 【SpringBoot系列4】SpringBoot定制自己的bean

    起因:SpringBoot我是越用越喜欢,但当SpringBoot出了问题的时候,我却无从下手,因为封装实在是太高度化了.然后之前有一个需求,使用SpringBoot提供的StringRedisTem ...

  6. bean的singleton(没有看到生命周期范围??)

    4.5.1 The singleton scope Only one shared instance of a singleton bean is managed, and all requests ...

  7. Spring Bean Life Cycle Methods – InitializingBean, DisposableBean, @PostConstruct, @PreDestroy and *Aware interfaces

    Spring Beans are the most important part of any Spring application. Spring ApplicationContext is res ...

  8. 【Feign】@FeignClient相同名字错误 The bean 'xxx.FeignClientSpecification', defined in null, could not be registered

    The bean 'xxx.FeignClientSpecification', defined in null, could not be registered. A bean with that ...

  9. springboot easypoi 报错The bean 'beanNameViewResolver', defined in class path resource [cn/afterturn/e

    事故现场: The bean 'beanNameViewResolver', defined in class path resource [cn/afterturn/easypoi/configur ...

随机推荐

  1. 剑指Offer 47. 求1+2+3+...+n (其他)

    题目描述 求1+2+3+...+n,要求不能使用乘除法.for.while.if.else.switch.case等关键字及条件判断语句(A?B:C). 题目地址 https://www.nowcod ...

  2. web(八)CSS选择器

    标签选择器 使用html标签筛选需要渲染的网页元素. 使用场景 修改标签的默认样式,例如ul li 有默认的内边距,开发时应去掉标签的默认样式. 设定全局字体样式. 根据分辨率设定html标签的默认字 ...

  3. C程序第三次作业

    6-1 输出月份英文名 PTA提交列表: 1.设计思路 (1)主要描述题目算法 第一步:将十二个月的名称分别赋值给一维数组指针,定义用于返回的数据类型. 第二步:遍历数组,满足若n在1-12范围则将m ...

  4. php字符串统计次数的各种方法(转)

    <?php $str = 'AbCdEfGaBcDeFgH0234;,!-AaBbCcDdEeFfGg'; $str = strtoupper($str); // 不区分大小写时,全部转换成大写 ...

  5. if 循环

    age_of_princal = 56guess_age = int(input(">>:")) if guess_age == age_of_princal: pri ...

  6. winform中devexpress bindcommand无效的解决方法

    正常绑定,编译运行无报错,但无法执行command fluentAPI.BindCommand(commandButton, (x, p) => x.DoSomething(p), x => ...

  7. Linux内核分析第七次作业

    分析Linux内核创建一个新进程的过程 Linux中创建进程一共有三个函数: 1. fork,创建子进程 2. vfork,与fork类似,但是父子进程共享地址空间,而且子进程先于父进程运行. 3. ...

  8. SQL查:询结果区分大小写

    在MS SQL2005中的方法: 1)select * from user where name collate Chinese_PRC_CS_AS like 'A$%B%' escape '$'; ...

  9. win7文件夹带锁标志如何去除?win7去除文件夹带锁标志的方法

    win7文件夹带锁标志如何去除?win7去除文件夹带锁标志的方法 http://www.xitongcheng.com/jiaocheng/win7_article_30333.html 具体方法如下 ...

  10. Java String对象的问题 String s="a"+"b"+"c"+"d"

    1, String s="a"+"b"+"c"+"d"创建了几个对象(假设之前串池是空的) 2,StringBuilde ...