0
点赞
收藏
分享

微信扫一扫

循环依赖报错java: Annotation processing is not supported for module cycles. Please ensure that all mod


报错

Error:java: Annotation processing is not supported for module cycles. Please ensure that all modules from cycle [changgou-common,changgou-service-user-api] are excluded from annotation processing

从字面意思理解,也就是changgou-common,changgou-service-user-api两个模块之间互相依赖,在进行Annotation处理时,形成了死循环。


解决方案

从字面意思来看,可能是pom文件中,两个模块进行了相互引用(我印象里没有),经过检查,这两个模块的pom文件中确实不存在相互引用。

查找了一个解决方案,解决问题:

1.进行模块之间依赖的分析:

循环依赖报错java: Annotation processing is not supported for module cycles. Please ensure that all mod_解决方案

2.如果两个模块间存在依赖死循环,会出现标红提示

循环依赖报错java: Annotation processing is not supported for module cycles. Please ensure that all mod_maven_02

3.点击这两个标红的模块,然后对模块进行重新设置

循环依赖报错java: Annotation processing is not supported for module cycles. Please ensure that all mod_解决方案_03

4.删除掉不需要的模块,也就是将两个模块之间的依赖删除掉。changgou-common中删除掉changgou-service-user-api,changgou-service-user-api中删除掉changgou-common。即可

循环依赖报错java: Annotation processing is not supported for module cycles. Please ensure that all mod_java_04
















举报

相关推荐

0 条评论