I'm working on an app that uses the Feign client to call another service. The problem now is I keep getting a 301 thrown as an Exception. How do I propagate this to ignore 301 as an error and fetch the actual response from the service?
This is the client interface for the service I am trying to call.
package com.eventmanager.events.client;
import com.eventmanager.events.client.mappings.Auth;
import com.eventmanager.events.responses.Response;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestHeader;
@FeignClient(value = "auth-service")
public interface AuthClient {
@GetMapping("/api/v1/auth")
public Response<Auth> getLoggedUser(@RequestHeader(value = "Authorization") String authorization);
}