Зуул не пойдёт в сервис - PullRequest
       8

Зуул не пойдёт в сервис

0 голосов
/ 26 апреля 2019

Зуул не направляется на студенческий сервис, который зарегистрирован на Eureka Server используя Greenwich.SR1

bootstrap.yml

server:
  port: 17005

# Eureka server details and its refresh time
eureka:
  instance:
    leaseRenewalIntervalInSeconds: 1
    leaseExpirationDurationInSeconds: 2
  client:
    registry-fetch-interval-seconds: 30
    serviceUrl:
      defaultZone: http://localhost:8761/eureka/
    healthcheck:
      enabled: true
    lease:
      duration: 5
    instance:
      lease-expiration-duration-in-seconds: 5
      lease-renewal-interval-in-seconds: 30

# Current service name to be used by the eureka server
spring:
  application:
    name: app-gateway

# Microservices routing configuration
zuul:
  routes:        
    students:
      path: /students/**
      serviceId: student-service
  host:
    socket-timeout-millis: 30000

hystrix:
  command:
    default:
      execution:
        isolation:
          thread:
            timeoutInMilliseconds: 30000

Я добавил PreFilter для регистрации запроса от пользовательского интерфейса. Всякий раз, когда запрос от пользовательского интерфейса попадает в Zuul - я наблюдаю ниже в журналах, но не продолжаю после - Не получаю перенаправления в службу студентов.

Request Method : GET Request URL : http://localhost:17005/students/School2
2019-04-26 21:45:54.314  INFO 18196 --- [o-17005-exec-10] c.netflix.config.ChainedDynamicProperty  : Flipping property: student-service.ribbon.ActiveConnectionsLimit to use NEXT property: niws.loadbalancer.availabilityFilteringRule.activeConnectionsLimit = 2147483647
2019-04-26 21:45:54.387  INFO 18196 --- [o-17005-exec-10] c.n.u.concurrent.ShutdownEnabledTimer    : Shutdown hook installed for: NFLoadBalancer-PingTimer-student-service
2019-04-26 21:45:54.387  INFO 18196 --- [o-17005-exec-10] c.netflix.loadbalancer.BaseLoadBalancer  : Client: student-service instantiated a LoadBalancer: DynamicServerListLoadBalancer:{NFLoadBalancer:name=student-service,current list of Servers=[],Load balancer stats=Zone stats: {},Server stats: []}ServerList:null
2019-04-26 21:45:54.682  INFO 18196 --- [o-17005-exec-10] c.n.l.DynamicServerListLoadBalancer      : Using serverListUpdater PollingServerListUpdater
2019-04-26 21:45:54.720  INFO 18196 --- [o-17005-exec-10] c.netflix.config.ChainedDynamicProperty  : Flipping property: student-service.ribbon.ActiveConnectionsLimit to use NEXT property: niws.loadbalancer.availabilityFilteringRule.activeConnectionsLimit = 2147483647
2019-04-26 21:45:54.723  INFO 18196 --- [o-17005-exec-10] c.n.l.DynamicServerListLoadBalancer      : DynamicServerListLoadBalancer for client student-service initialized: DynamicServerListLoadBalancer:{NFLoadBalancer:name=student-service,current list of Servers=[192.168.56.1:56567],Load balancer stats=Zone stats: {defaultzone=[Zone:defaultzone;  Instance count:1;   Active connections count: 0;    Circuit breaker tripped count: 0;   Active connections per server: 0.0;]
},Server stats: [[Server:192.168.56.1:56567;    Zone:defaultZone;   Total Requests:0;   Successive connection failure:0;    Total blackout seconds:0;   Last connection made:Thu Jan 01 05:30:00 IST 1970;  First connection made: Thu Jan 01 05:30:00 IST 1970;    Active Connections:0;   total failure count in last (1000) msecs:0; average resp time:0.0;  90 percentile resp time:0.0;    95 percentile resp time:0.0;    min resp time:0.0;  max resp time:0.0;  stddev resp time:0.0]
]}ServerList:org.springframework.cloud.netflix.ribbon.eureka.DomainExtractingServerList@42abe3b4
2019-04-26 21:45:55.742  INFO 18196 --- [erListUpdater-0] c.netflix.config.ChainedDynamicProperty  : Flipping property: student-service.ribbon.ActiveConnectionsLimit to use NEXT property: niws.loadbalancer.availabilityFilteringRule.activeConnectionsLimit = 2147483647

В микросервисах нет трассировки исключений.

Ответ на пользовательский интерфейс: тип = не найдено, статус = 404

Пожалуйста, помогите при установлении этой маршрутизации.

...