- 新しい順
- 投票が多い順
- コメントが多い順
Hi Bhanu,
First of all, what you're trying to do is perfectly feasible with the configuration you've mentioned, so don't give up - it's probably a configuration problem somewhere.
Now here are a few things to test/check:
- WebSocket Support on ALB
Application Load Balancers do support WebSocket traffic, but you need to ensure that the 'Connection' header is set to 'Upgrade' and the 'Upgrade' header is set to 'websocket' during the WebSocket handshake. You can see some header example here
- WebSocket Path in the Application
As 404 is a NOT FOUND HTTP error, ensure that the WebSocket endpoint path is correctly specified in the ALB listener rules and that it matches the path configured in your Golang application using the Gorilla framework
- Look at the logs
One thing to try is to connect directly to the WebSocket service of one of your fargate task to bypass the ALB and to rule out any issues with the ALB configuration. If you cannot make it work, check the logs.
If websocket are working from ECS standpoint, then you can enable [ALB access Logs] (https://docs.aws.amazon.com/elasticloadbalancing/latest/application/load-balancer-access-logs.html) to get more insight into the requests that are reaching the ALB and how they are being handled.
Good luck !
関連するコンテンツ
- AWS公式更新しました 1年前
- AWS公式更新しました 3年前
- AWS公式更新しました 9ヶ月前