Error while getting response from load balancer

0

I have deployed react application on Application load balancer and there are two ec2 instance in a target group,the issue is that the web page loads properly after multiple refresh or else gives blank screen because of the error "Uncaught SyntaxError: Unexpected token '<'". in the console and only loads the static index.html.

The application loads by directly accessing the instance without any error and even after multiple refreses. The issues get encountered in load balancer only. I have also tried changing the health check configuration but didn't worked and the checkups are also healthy. I also tried deploying the application with classic load balancer but issues were faced.

What might be the possible issue because it successfully responds sometimes and mostly reponds with errors?

  • The issue is most likely on the application side. Using Chrome developer tools, can you please capture the Request and Responses when the page loads and when you observe this error? This will help us better understand the issue.

1개 답변
0

This error may be related to React application also. Would recommend to use your browser dev tools or any available React Developer Tools to debug the same. This will provide some insights where things are failing.

profile pictureAWS
전문가
답변함 일 년 전
  • There is no issue in the application i have checked and also it works fine by directly accessing the instance. The link for load balancer:http://projectbalancer-1437849666.ap-south-1.elb.amazonaws.com/ You can have a look,and let me know what is causing the load balancer to show this error. Inorder to access the page you have to refresh multiple times and i have also mentioned to which server it is accessing either 1 or 2

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인

관련 콘텐츠