What does "cwDuration" field of "AwsLambdaInvocation" mean?

Summary page for AWS lambda functions contains the metric presented by the following query:

SELECT percentile(cwDuration, 50) as 'ms', percentile(duration, 50) as 'duration', FROM AwsLambdaInvocation WHERE (`entityGuid`='...') SINCE 604800 seconds AGO

I suppose that cwDuration means cloud watch duration but what does it actually mean? What is the difference between duration and cwDuration fields? I can find the answer neither in New Relic documentation nor in the google.
Thank you.

Hi @aandrusyk,

Thanks for posting your question here in Explorers Hub! I also couldn’t find any mention to cwDuration in our Data Dictionary for AwsLambdaInvocation, so I asked one of our Lambda Monitoring Devs.

CloudWatch Duration is a metric delivered to New Relic from AWS CloudWatch.

We rename it to cwDuration to differentiate it from our own duration, which is less precise.

If cwDuration exists, we use that as duration. If it doesn’t (older agent, for example), we’ll fall back to the old duration metric.

Thanks again for your question! TIL!

1 Like