假期的学习 2022-03-02 21:03
浏览 65
已结题

学习springcloud时,学习到openfeign的时候启动feign-order80时报错:'http://localhost:8761/eureka,如何解决?

主要报错信息如下:
学习springcloud时,学习到openfeign的时候启动feign-order80时报错:Request execution error. endpoint=DefaultEndpoint{ serviceUrl='http://localhost:8761/eureka/}
具体报错信息如下:

E:\smallTools\jdk\java-se-8u41-ri\bin\java.exe -XX:TieredStopAtLevel=1
2022-03-02 20:44:21.954  INFO 3152 --- [  restartedMain] .e.DevToolsPropertyDefaultsPostProcessor : Devtools property defaults active! Set 'spring.devtools.add-properties' to 'false' to disable

  .   ____          _            __ _ _
 /\\ / ___'_ __ _ _(_)_ __  __ _ \ \ \ \
( ( )\___ | '_ | '_| | '_ \/ _` | \ \ \ \
 \\/  ___)| |_)| | | | | || (_| |  ) ) ) )
  '  |____| .__|_| |_|_| |_\__, | / / / /
 =========|_|==============|___/=/_/_/_/
 :: Spring Boot ::        (v2.2.5.RELEASE)

2022-03-02 20:44:23.316  INFO 3152 --- [  restartedMain] com.feng.springcloud.OrderFeignMain80    : No active profile set, falling back to default profiles: default
2022-03-02 20:44:26.114  WARN 3152 --- [  restartedMain] c.n.c.sources.URLConfigurationSource     : No URLs will be polled as dynamic configuration sources.
2022-03-02 20:44:26.114  INFO 3152 --- [  restartedMain] c.n.c.sources.URLConfigurationSource     : To enable URLs as dynamic configuration sources, define System property archaius.configurationSource.additionalUrls or make config.properties available on classpath.
2022-03-02 20:44:26.198  INFO 3152 --- [  restartedMain] o.s.s.concurrent.ThreadPoolTaskExecutor  : Initializing ExecutorService 'applicationTaskExecutor'
2022-03-02 20:44:27.535  INFO 3152 --- [  restartedMain] o.s.cloud.commons.util.InetUtils         : Cannot determine local hostname
2022-03-02 20:44:27.557  WARN 3152 --- [  restartedMain] ockingLoadBalancerClientRibbonWarnLogger : You already have RibbonLoadBalancerClient on your classpath. It will be used by default. As Spring Cloud Ribbon is in maintenance mode. We recommend switching to BlockingLoadBalancerClient instead. In order to use it, set the value of `spring.cloud.loadbalancer.ribbon.enabled` to `false` or remove spring-cloud-starter-netflix-ribbon from your project.
2022-03-02 20:44:27.579  INFO 3152 --- [  restartedMain] o.s.b.a.e.web.EndpointLinksResolver      : Exposing 2 endpoint(s) beneath base path '/actuator'
2022-03-02 20:44:27.637  INFO 3152 --- [  restartedMain] o.s.c.n.eureka.InstanceInfoFactory       : Setting initial instance status as: STARTING
2022-03-02 20:44:27.661  INFO 3152 --- [  restartedMain] com.netflix.discovery.DiscoveryClient    : Initializing Eureka in region us-east-1
2022-03-02 20:44:27.720  INFO 3152 --- [  restartedMain] c.n.d.provider.DiscoveryJerseyProvider   : Using JSON encoding codec LegacyJacksonJson
2022-03-02 20:44:27.720  INFO 3152 --- [  restartedMain] c.n.d.provider.DiscoveryJerseyProvider   : Using JSON decoding codec LegacyJacksonJson
2022-03-02 20:44:27.813  INFO 3152 --- [  restartedMain] c.n.d.provider.DiscoveryJerseyProvider   : Using XML encoding codec XStreamXml
2022-03-02 20:44:27.813  INFO 3152 --- [  restartedMain] c.n.d.provider.DiscoveryJerseyProvider   : Using XML decoding codec XStreamXml
2022-03-02 20:44:27.926  INFO 3152 --- [  restartedMain] c.n.d.s.r.aws.ConfigClusterResolver      : Resolving eureka endpoints via configuration
2022-03-02 20:44:28.029  INFO 3152 --- [  restartedMain] com.netflix.discovery.DiscoveryClient    : Disable delta property : false
2022-03-02 20:44:28.029  INFO 3152 --- [  restartedMain] com.netflix.discovery.DiscoveryClient    : Single vip registry refresh property : null
2022-03-02 20:44:28.029  INFO 3152 --- [  restartedMain] com.netflix.discovery.DiscoveryClient    : Force full registry fetch : false
2022-03-02 20:44:28.029  INFO 3152 --- [  restartedMain] com.netflix.discovery.DiscoveryClient    : Application is null : false
2022-03-02 20:44:28.029  INFO 3152 --- [  restartedMain] com.netflix.discovery.DiscoveryClient    : Registered Applications size is zero : true
2022-03-02 20:44:28.029  INFO 3152 --- [  restartedMain] com.netflix.discovery.DiscoveryClient    : Application version is -1: true
2022-03-02 20:44:28.029  INFO 3152 --- [  restartedMain] com.netflix.discovery.DiscoveryClient    : Getting all instance registry info from the eureka server
2022-03-02 20:44:32.157 ERROR 3152 --- [  restartedMain] c.n.d.s.t.d.RedirectingEurekaHttpClient  : Request execution error. endpoint=DefaultEndpoint{ serviceUrl='http://localhost:8761/eureka/}

com.sun.jersey.api.client.ClientHandlerException: java.net.ConnectException: Connection refused: connect
    at com.sun.jersey.client.apache4.ApacheHttpClient4Handler.handle(ApacheHttpClient4Handler.java:187) ~[jersey-apache-client4-1.19.1.jar:1.19.1]
    at com.sun.jersey.api.client.filter.GZIPContentEncodingFilter.handle(GZIPContentEncodingFilter.java:123) ~[jersey-client-1.19.1.jar:1.19.1]
    at com.netflix.discovery.EurekaIdentityHeaderFilter.handle(EurekaIdentityHeaderFilter.java:27) ~[eureka-client-1.9.17.jar:1.9.17]
    at com.sun.jersey.api.client.Client.handle(Client.java:652) ~[jersey-client-1.19.1.jar:1.19.1]
    at com.sun.jersey.api.client.WebResource.handle(WebResource.java:682) ~[jersey-client-1.19.1.jar:1.19.1]
    at com.sun.jersey.api.client.WebResource.access$200(WebResource.java:74) ~[jersey-client-1.19.1.jar:1.19.1]
    at com.sun.jersey.api.client.WebResource$Builder.get(WebResource.java:509) ~[jersey-client-1.19.1.jar:1.19.1]
    at com.netflix.discovery.shared.transport.jersey.AbstractJerseyEurekaHttpClient.getApplicationsInternal(AbstractJerseyEurekaHttpClient.java:196) ~[eureka-client-1.9.17.jar:1.9.17]
    
  • 写回答

1条回答 默认 最新

  • 假期的学习 2022-03-03 08:15
    关注

    #报错:Request execution error. endpoint=DefaultEndpoint{ serviceUrl='http://localhost:8761/eureka/}
    错误原因找到了:对应微服务的application.yaml配置文件里面的配置(一个单词)写错了
    eureka: 写成了euereka:

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?

问题事件

  • 系统已结题 3月11日
  • 已采纳回答 3月3日
  • 创建了问题 3月2日

悬赏问题

  • ¥30 motoradmin系统的多对多配置
  • ¥15 求组态王串口自定义通信配置方法或代码?
  • ¥15 实验 :UML2.0 结构建模
  • ¥20 用vivado写数字逻辑实验报告撰写,FPGA实验
  • ¥15 为什么shp文件会有这种小方块?
  • ¥15 ecplise在连接数据库时显示加载驱动成功但是数据库连接失败
  • ¥15 visionmaster启动失败,提示为“机器不满足授权而被禁用”
  • ¥15 IDEA中圈复杂度如何具体设置
  • ¥50 labview采集不了数据
  • ¥15 Multisim红外倒车雷达仿真中距离问题