I have microservices(in different programming languages) running on an EC2 instance. On production, I notice a few 502 Bad Gateway Errors when these services try to interact with each other. Also in the logs of the requested service, it doesn't show any API call is being hit
example service A calls service B, but in service B logs there is nothing to indicate that a call came from service A.
Can it be AWS load balancer issue? Any help would be appreciated. Thanks in advance.
Solution tried: We tried making http/https connection agents in each service but still we get this issue.
Update: In lb logs, the API is logged, but the target response code shows "-" whereas lb response code shows 502 or 504. Does it mean that lb is not able to handle the traffic or my application?
Also, what can be a possible solution?