AWS Lambda "duration" 是实时测量的吗?
Is AWS Lambda "duration" measured in real time?
使用 AWS Lambda,我需要为函数执行 "duration" 付费。持续时间是以 CPU 时间还是实时衡量的?换句话说,我是否在执行查询 SQL 数据库等 IO 操作时被收费?
从他们的定价详细信息页面 (https://aws.amazon.com/lambda/pricing/):"Duration is calculated from the time your code begins executing until it returns or otherwise terminates, rounded up to the nearest 100ms." 所以我想说这意味着您在等待外部资源的响应时会被收费。
这也意味着您的超时持续时间需要足够长以应对来自外部资源的缓慢响应,否则 Lambda 将超时。
你的函数使用lambda serverless算力都是实时的
使用 AWS Lambda,我需要为函数执行 "duration" 付费。持续时间是以 CPU 时间还是实时衡量的?换句话说,我是否在执行查询 SQL 数据库等 IO 操作时被收费?
从他们的定价详细信息页面 (https://aws.amazon.com/lambda/pricing/):"Duration is calculated from the time your code begins executing until it returns or otherwise terminates, rounded up to the nearest 100ms." 所以我想说这意味着您在等待外部资源的响应时会被收费。
这也意味着您的超时持续时间需要足够长以应对来自外部资源的缓慢响应,否则 Lambda 将超时。
你的函数使用lambda serverless算力都是实时的