Application failed to connect to Nacos server: ““

古城微笑少年丶 2022-12-28 08:11 285阅读 0赞

错误界面:

  1. E:\jdk\jdk1.8.0_151\bin\java -XX:TieredStopAtLevel=1 …………………
  2. . ____ _ __ _ _
  3. /\\ / ___'_ __ _ _(_)_ __ __ _ \ \ \ \ ( ( )\___ | '_ | '_| | '_ \/ _` | \ \ \ \
  4. \\/ ___)| |_)| | | | | || (_| | ) ) ) )
  5. ' |____| .__|_| |_|_| |_\__, | / / / /
  6. =========|_|==============|___/=/_/_/_/
  7. :: Spring Boot :: (v2.2.1.RELEASE)
  8. 2020-08-25 22:40:12.628 ERROR 10080 --- [ main] o.s.b.d.LoggingFailureAnalysisReporter :
  9. ***************************
  10. APPLICATION FAILED TO START
  11. ***************************
  12. Description:
  13. Application failed to connect to Nacos server: ""
  14. Action:
  15. Please check your Nacos server config
  16. Process finished with exit code 1

问题分析:

如果在springboot项目中引入nacos配置中心的依赖,那就需要配置bootstrap.yml或者bootstrap.properties文件,不然就会出现错误

解决方法:

如果你需要把配置文件转移到nacos上,那就配置bootstrap.yml或者bootstrap.properties就好了,如果不需要转移,那就把nacos配置中心的注解注释掉就可以了

发表评论

表情:
评论列表 (有 0 条评论,285人围观)

还没有评论,来说两句吧...

相关阅读