Hacktoberfest 2026: los issues que los mantenedores marcaron para octubre, abiertos y aptos para principiantes. Explorar issues de Hacktoberfest

Suggestions for the modification of 'retrievedServiceInstance == null' in RetryableFeignBlockingLoadBalancerClient#execute

Abierto
#1,203 1 comentario 0 reacciones 0 asignados Ver en GitHub

Los mantenedores suelen responder en 1 día

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
3/5
Tiempo estimado
1-2 días
Aptitud para principiantes
38/100
Tipo de issue
Nueva funcionalidad
Claridad
Bastante claro
Estado de actividad
Estancado
Stack tecnológico
java, spring
Área
api, backend

Línea de trabajo

Comienza en RetryableFeignBlockingLoadBalancerClient.java alrededor de la línea 191 y sigue LoadBalancerUtils.executeWithLoadBalancerLifecycleProcessing. Compara su gestión de serviceInstance == null con FeignBlockingLoadBalancerClient y verifica después que los reintentos agotados eviten la resolución directa del host y produzcan el resultado esperado de servicio no disponible.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

waiting-for-triage

Is your feature request related to a problem? Please describe.

The same interface behaves completely differently in my projects. In one case, it throws a FeignException$ServiceUnavailable exception, while in the other, it throws an UnknownHostException (And it took up to 10 seconds).

After debugging, I found that the inconsistent exception behaviors were caused by the varying implementations of the feign.Client class due to the involvement of spring-retry.

Describe the solution you'd like

The RetryableFeignBlockingLoadBalancerClient appears to reference the handling approach of RetryLoadBalancerInterceptor, but it doesn't perform special handling for the case where serviceInstance == null, unlike FeignBlockingLoadBalancerClient.

I feel that for the case where serviceInstance == null, after retry attempts are exhausted, the RetryableFeignBlockingLoadBalancerClient should return a result similar to that of the FeignBlockingLoadBalancerClient.

Describe alternatives you've considered

I referenced the handling of the serviceInstance == null case in FeignBlockingLoadBalancerClient and modified RetryableFeignBlockingLoadBalancerClient accordingly. It now perfectly meets my expectations.

Image

Additional context

In the code at RetryableFeignBlockingLoadBalancerClient.java:191, within the LoadBalancerUtils.executeWithLoadBalancerLifecycleProcessing method, the feign.Client is directly used to execute the request. Due to the reason that serviceInstance == null, the Client attempts to resolve the host (serviceId), this took too long.

Image

Image

Lenguaje dominante
Java
Estrellas
1.3k
Forks
835
Merge medio
23 h 57 min
PR fusionados (30 d)
25

Preparar el entorno

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de spring-cloud/spring-cloud-openfeign

Todos los issues de spring-cloud/spring-cloud-openfeign

Issues similares

Más issues de Java

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.