Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
404 views
in Technique[技术] by (71.8m points)

amazon web services - Slow response for the first request with AWS ALB

I am using AWS and setup a VPC in us-west-2. There are public and private subnets in zone B and C. Mainly I use zone b only.

I have a NAT Gateway in public subnet in zone B and a t3a.large EC2 instance in private subnet in zone b too. I can run curl https://google.com/ in my t3a instance in private subnet and the response time is very fast.

For ALB my setup is to listen 443 and forward it to my instance. I can curl locally on my instance and the respond time is very low too. However I am not sure why it is very very slow if I browse it with browser for the first time.

My application is full of XHR, and the slow response time only affect the very first request, for all sequential requests they are all fast.

When I have passed the first slow request and up to speed for me now. Another user with another computer starting to visit our site suffer from slow response time as he is newly visiting our site. The slow response time is definitely not caused by session or file transfer related issues.

Any ideas on what would be wrong?

question from:https://stackoverflow.com/questions/65622842/slow-response-for-the-first-request-with-aws-alb

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)
Waitting for answers

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...