关于org.springframework.cloud.context.named.NamedContextFactory$Specification 的问题!

简介: 关于org.springframework.cloud.context.named.NamedContextFactory$Specification 的问题!

今天在启动springboot项目时出现了一个小插曲,昨天能跑起来的程序突然就爆出来了一个错误,真的是让人匪夷所思!报错信息是这样的:

Caused by: java.lang.ClassNotFoundException: org.springframework.cloud.context.named.NamedContextFactory$Specification
    at java.net.URLClassLoader.findClass(URLClassLoader.java:382)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
    at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:349)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
    ... 34 common frames omitted

很明显上面提示 org.springframework.cloud 下的没有被找到,那我们就去maven仓库找一下这个依赖进行导入!
在这里插入图片描述
在这里插入图片描述
在依赖导入之后项目就可以正常启动了!!!至于为什么之前能够正常启动而突然报错,这个由于能力问题暂时没有排查出来,上面的解决方法是个人见解,可能会有问题和错误,希望小伙伴们可以指正😘😘。

目录
相关文章
IDEA添加Swagger2:Parameter 0 of method linkDiscoverers in org. springframework hateoas.config.Hateoasconfiguration required a single bean, but 15 were found:
IDEA添加Swagger2:Parameter 0 of method linkDiscoverers in org. springframework hateoas.config.Hateoasconfiguration required a single bean, but 15 were found
|
2月前
Consider defining a bean of type 'org.springframework.security.authentication.AuthenticationManager' in your configuration.
Consider defining a bean of type 'org.springframework.security.authentication.AuthenticationManager' in your configuration.
64 0
|
5月前
SpringCloud启动Consider defining a bean of type ‘org.springframework.web.client.RestTemplate‘ in your
SpringCloud启动Consider defining a bean of type ‘org.springframework.web.client.RestTemplate‘ in your
92 1
|
5月前
解决The injection point has the following annotations:@org.springframework.beans.factory.annotation错误~
解决The injection point has the following annotations:@org.springframework.beans.factory.annotation错误~
792 0
|
12月前
|
Java
Caused by: org.springframework.context.ApplicationContextException: Unable to start ServletWebServer
Caused by: org.springframework.context.ApplicationContextException: Unable to start ServletWebServer
|
Java Spring
required a bean of type ‘org.springframework.web.client.RestTemplate‘ that could not be found.
required a bean of type ‘org.springframework.web.client.RestTemplate‘ that could not be found.
required a bean of type ‘org.springframework.web.client.RestTemplate‘ that could not be found.
|
Java Spring
[org.springframework.cloud.openfeign.FeignClientFactoryBean] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
这个日志信息是Spring框架中的一个`BeanPostProcessor`在启动时输出的。它在扫描应用程序中定义的所有Bean并将它们注册到应用程序上下文之前执行。然后,它检查每个Bean是否适合被所有`BeanPostProcessor`处理,也就是是否可以被动态代理拦截。
1371 1
|
前端开发 Java 应用服务中间件
Error configuring application listener of class org.springframework.web.context.ContextLoader
Error configuring application listener of class org.springframework.web.context.ContextLoader
Error configuring application listener of class org.springframework.web.context.ContextLoader
|
Java 应用服务中间件 Maven
Error configuring application listener of class org.springframework.web.context.ContextLoaderListene
Error configuring application listener of class org.springframework.web.context.ContextLoaderListene
106 0
|
缓存 Java Maven
严重: Error configuring application listener of class org.springframework.web.context.ContextLoaderLis
严重: Error configuring application listener of class org.springframework.web.context.ContextLoaderLis
128 0
严重: Error configuring application listener of class org.springframework.web.context.ContextLoaderLis