Lambda latency is increasing when the traffic is high

0

Hi Team,

I have a lambda which basically performs the data transformation on service response. The lambda duration metrics is slowly spiking when the traffic is increasing.

Referred already :

Things already configured for lambda:

  • Auto scaling the provisioned concurrency of lambda.
  • I have enabled the X - Ray trace for the lambda.
  • Found out that, Invocation phase duration is increasing when there is more incoming traffic.

Screenshots for reference:

Any idea why the invocation phase is increasing & how to handle this ?

1 Answer
0

I don't think there's enough information here to solve your problem.

For example, if your Lambda function is interacting with a back-end database then it's possible that under load that database is responding slower and that is causing an increase in Lambda function time and latency.

But without a detailed analysis of the code and what it is doing it's complete guess work.

If it were me, I'd be using X-Ray, instrumenting the code and then analysing where the additional latency is coming from when the function is under load.

profile pictureAWS
EXPERT
answered 2 years ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions