Question:
Hi,
I have implemeted a simple zuul service where I am forwarding the incoming requests to their corresponding Akana APIS. I have configured the routes properly, but I always receive 500 Internal server error response, also there are no errors received on zuul.
However, I explicitly created a rest call from zuul to akana and that works perfectly. Only when zuul routes the request, it fails. Routes to other servers are working fine too.
Is there anything zuul is doing internally to block these calls to Akana?
Comment From: spencergibb
Without more detail there's no way of us knowing.
Comment From: priyanka010392
It is a very basic application, just configured the routes as below:
zuul.routes.user-management.path=/user-management/**
zuul.routes.user-management.url=https://host/user-management/ ---- this route works and i get the response
zuul.routes.user-management.url=https://akanahost/user-management/
when I replace the akana url it doesnt work
Comment From: priyanka010392
I have tested tha akana url from postman and its working. Just to test from zuul I have tried below in the pre filter
RestTemplate rt = new RestTemplate(); HttpEntity requestEntity = new HttpEntity(headers); System.out.println("rest res:: "+ rt.exchange("https://akanahost/user-management/", HttpMethod.GET, requestEntity, String.class));
and its giving me correct response
Comment From: spencergibb
I'm afraid that still doesn't help. Without some way to replicate the problem we can't investigate.
Comment From: priyanka010392
Hey, I found the solution after banging my head for a day. Akana gateway was not able to identify the requests because of the proxy headers that were getting added by Zuul while routing. I disabled them as below and the flow works now: zuul.addProxyHeaders = false
Thanks for responding but I could not share much detail due to privacy concerns.