栏目分类:
子分类:
返回
名师互学网用户登录
快速导航关闭
当前搜索
当前分类
子分类
实用工具
热门搜索
名师互学网 > IT > 软件开发 > 后端开发 > Java

解决【BUILD FAILURE】2 errors程序包org.springframework.cloud.netflix.zuul不存在;StarterZuul.java:[10,2] 找不到符号

Java 更新时间: 发布时间: IT归档 最新发布 模块sitemap 名妆网 法律咨询 聚返吧 英语巴士网 伯小乐 网商动力

解决【BUILD FAILURE】2 errors程序包org.springframework.cloud.netflix.zuul不存在;StarterZuul.java:[10,2] 找不到符号

zuulClient Maven install报错信息:
[INFO] Scanning for projects...
[INFO] 
[INFO] -----------------------< com.carina:zuul-client >-----------------------
[INFO] Building zuul-client 0.0.1-SNAPSHOT
[INFO] --------------------------------[ jar ]---------------------------------
[WARNING] The POM for org.springframework.cloud:spring-cloud-starter-eureka:jar:1.4.0.RELEASE is invalid, transitive dependencies (if any) will not be available, enable debug logging for more details
[WARNING] The POM for org.springframework.cloud:spring-cloud-starter-config:jar:1.4.0.RELEASE is invalid, transitive dependencies (if any) will not be available, enable debug logging for more details
[WARNING] The POM for org.springframework.cloud:spring-cloud-starter-zuul:jar:1.4.0.RELEASE is invalid, transitive dependencies (if any) will not be available, enable debug logging for more details
[INFO] 
[INFO] --- maven-resources-plugin:2.6:resources (default-resources) @ zuul-client ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 1 resource
[INFO] Copying 0 resource
[INFO] 
[INFO] --- maven-compiler-plugin:3.1:compile (default-compile) @ zuul-client ---
[INFO] Changes detected - recompiling the module!
[INFO] Compiling 1 source file to F:Ececlipse64zuul-clienttargetclasses
[INFO] -------------------------------------------------------------
[ERROR] COMPILATION ERROR : 
[INFO] -------------------------------------------------------------
[ERROR] /F:/Ec/eclipse64/zuul-client/src/main/java/com/carina/StarterZuul.java:[5,46] 程序包org.springframework.cloud.netflix.zuul不存在
[ERROR] /F:/Ec/eclipse64/zuul-client/src/main/java/com/carina/StarterZuul.java:[10,2] 找不到符号
  符号: 类 EnableZuulProxy
[INFO] 2 errors 
[INFO] -------------------------------------------------------------
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  1.319 s
[INFO] Finished at: 2022-04-27T15:21:34+08:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.1:compile (default-compile) on project zuul-client: Compilation failure: Compilation failure: 
[ERROR] /F:/Ec/eclipse64/zuul-client/src/main/java/com/carina/StarterZuul.java:[5,46] 程序包org.springframework.cloud.netflix.zuul不存在
[ERROR] /F:/Ec/eclipse64/zuul-client/src/main/java/com/carina/StarterZuul.java:[10,2] 找不到符号
[ERROR]   符号: 类 EnableZuulProxy
[ERROR] -> [Help 1]
[ERROR] 
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR] 
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException

解决方案: 将Edgware.RELEASE改为Dalston.RELEASE

SpringCloud版本:  我的SpringBoot版本:

		org.springframework.boot
		spring-boot-starter-parent
		1.5.9.RELEASE
 
可参考以下文章对应版本

SpringCloud与SpringBoot的版本对应关系_richest_qi的博客-CSDN博客_springboot和springcloud版本对应关系在SpringCloud官网(https://spring.io/projects/spring-cloud)可以看到,当前(2021年11月),SpringCloud的最新GA版本是2020.0.4这一版。除了2020.0.X版本外,SpringCloud之前的版本名称是伦敦地铁站的站名命名,且首字母顺序与版本时间顺序一致,如,AngelBrixtonCamdenDalstonEdgwareFinchleyGreenwichHoxton当SpringCloud的发布内容积累到临界点或https://blog.csdn.net/qzw752890913/article/details/121073738

转载请注明:文章转载自 www.mshxw.com
本文地址:https://www.mshxw.com/it/842494.html
我们一直用心在做
关于我们 文章归档 网站地图 联系我们

版权所有 (c)2021-2022 MSHXW.COM

ICP备案号:晋ICP备2021003244-6号