项目启动一直报错,其他同事、其他模块都没有这个错误。
关键信息如下:
[Cause: [status code: 404] Could not find config for namespace - appId: m-ln-contractmanage, cluster: default, namespace: application, please check whether the configs are released in Apollo!]|@|
详细如下:
[INFO ]|@|[]|@|[]|@|[2020-07-06 18:54:48,513]|@|[org.springframework.context.support.PostProcessorRegistrationDelegate$BeanPostProcessorChecker]|@|[]|@|Bean 'segmentServiceBolt' of type [com.alipay.sofa.runtime.spring.factory.ReferenceFactoryBean] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)|@|
[INFO ]|@|[]|@|[]|@|[2020-07-06 18:54:48,515]|@|[org.springframework.context.support.PostProcessorRegistrationDelegate$BeanPostProcessorChecker]|@|[]|@|Bean 'segmentServiceBolt' of type [com.sun.proxy.$Proxy154] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)|@|
[INFO ]|@|[]|@|[]|@|[2020-07-06 18:54:48,598]|@|[org.springframework.context.support.PostProcessorRegistrationDelegate$BeanPostProcessorChecker]|@|[]|@|Bean 'org.mybatis.spring.boot.autoconfigure.MybatisAutoConfiguration' of type [org.mybatis.spring.boot.autoconfigure.MybatisAutoConfiguration$$EnhancerBySpringCGLIB$$b6a386be] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)|@|
[WARN ]|@|[]|@|[]|@|[2020-07-06 18:58:38,529]|@|[com.ctrip.framework.apollo.internals.RemoteConfigRepository]|@|[]|@|Load config failed, will retry in 1 SECONDS. appId: m-ln-contractmanage, cluster: default, namespaces: application|@|
[WARN ]|@|[]|@|[]|@|[2020-07-06 18:58:40,201]|@|[com.ctrip.framework.apollo.internals.AbstractConfigRepository]|@|[]|@|Sync config failed, will retry. Repository class com.ctrip.framework.apollo.internals.RemoteConfigRepository, reason: Load Apollo Config failed - appId: m-ln-contractmanage, cluster: default, namespace: application, url: http://172.29.12.147:8091/configs/m-ln-contractmanage/default/application?ip=10.11.33.151&messages=%7B%22details%22%3A%7B%22m-ln-contractmanage%2Bdefault%2Bapplication%22%3A33%7D%7D [Cause: [status code: 404] Could not find config for namespace - appId: m-ln-contractmanage, cluster: default, namespace: application, please check whether the configs are released in Apollo!]|@|
[WARN ]|@|[]|@|[]|@|[2020-07-06 19:03:38,675]|@|[com.ctrip.framework.apollo.internals.RemoteConfigRepository]|@|[]|@|Load config failed, will retry in 1 SECONDS. appId: m-ln-contractmanage, cluster: default, namespaces: application|@|
[WARN ]|@|[]|@|[]|@|[2020-07-06 19:03:40,102]|@|[com.ctrip.framework.apollo.internals.AbstractConfigRepository]|@|[]|@|Sync config failed, will retry. Repository class com.ctrip.framework.apollo.internals.RemoteConfigRepository, reason: Load Apollo Config failed - appId: m-ln-contractmanage, cluster: default, namespace: application, url: http://172.29.12.147:8091/configs/m-ln-contractmanage/default/application?ip=10.11.33.151&messages=%7B%22details%22%3A%7B%22m-ln-contractmanage%2Bdefault%2Bapplication%22%3A33%7D%7D [Cause: [status code: 404] Could not find config for namespace - appId: m-ln-contractmanage, cluster: default, namespace: application, please check whether the configs are released in Apollo!]|@|
[WARN ]|@|[]|@|[]|@|[2020-07-06 19:08:38,378]|@|[com.ctrip.framework.apollo.internals.RemoteConfigRepository]|@|[]|@|Load config failed, will retry in 1 SECONDS. appId: m-ln-contractmanage, cluster: default, namespaces: application|@|
[WARN ]|@|[]|@|[]|@|[2020-07-06 19:08:39,875]|@|[com.ctrip.framework.apollo.internals.AbstractConfigRepository]|@|[]|@|Sync config failed, will retry. Repository class com.ctrip.framework.apollo.internals.RemoteConfigRepository, reason: Load Apollo Config failed - appId: m-ln-contractmanage, cluster: default, namespace: application, url: http://172.29.12.147:8091/configs/m-ln-contractmanage/default/application?ip=10.11.33.151&messages=%7B%22details%22%3A%7B%22m-ln-contractmanage%2Bdefault%2Bapplication%22%3A33%7D%7D [Cause: [status code: 404] Could not find config for namespace - appId: m-ln-contractmanage, cluster: default, namespace: application, please check whether the configs are released in Apollo!]|@|
经过好几天的尝试,一直没解决。网上找各种方案,都试了,没效果。
偶然间,发现项目启动时,发现提示如下:
![](https://img-blog.csdnimg.cn/20200706192803356.png)
打开Breakpoints面板看看,(快捷键:Ctrl - Shift -F8 )-参考,看到确实有断点。然后把断点去了,重启IDEA。
再次启动项目,竟然笔直的走过去了。
详细如下:
[INFO ]|@|[]|@|[]|@|[2020-07-06 19:14:07,612]|@|[org.springframework.context.support.PostProcessorRegistrationDelegate$BeanPostProcessorChecker]|@|[]|@|Bean 'org.mybatis.spring.boot.autoconfigure.MybatisAutoConfiguration' of type [org.mybatis.spring.boot.autoconfigure.MybatisAutoConfiguration$$EnhancerBySpringCGLIB$$d03f022e] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)|@|
[INFO ]|@|[]|@|[]|@|[2020-07-06 19:14:17,086]|@|[org.springframework.context.support.PostProcessorRegistrationDelegate$BeanPostProcessorChecker]|@|[]|@|Bean 'sqlSessionFactory' of type [org.apache.ibatis.session.defaults.DefaultSqlSessionFactory] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)|@|
[INFO ]|@|[]|@|[]|@|[2020-07-06 19:14:17,098]|@|[org.springframework.context.support.PostProcessorRegistrationDelegate$BeanPostProcessorChecker]|@|[]|@|Bean 'sqlSessionTemplate' of type [org.mybatis.spring.SqlSessionTemplate] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)|@|
[INFO ]|@|[]|@|[]|@|[2020-07-06 19:14:17,102]|@|[org.springframework.context.support.PostProcessorRegistrationDelegate$BeanPostProcessorChecker]|@|[]|@|Bean 'pb1221Mapper' of type [org.mybatis.spring.mapper.MapperFactoryBean] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)|@|
反复试了几次,确实是这个原因导致。
结论:不要放过任何一个小细节,非常可能就是突破口。如有问题,欢迎沟通。不喜勿喷!