Skip to content

Conversation

connorkoch
Copy link
Contributor

@connorkoch connorkoch commented Sep 18, 2024

Lambda has added support for connecting to Kafka streams via Event Source Mappings (see: https://docs.aws.amazon.com/lambda/latest/dg/with-msk.html). This comes with the addition of a new CW metric under the AWS/Lambda namespace, OffsetLag (see: https://aws.amazon.com/blogs/compute/offset-lag-metric-for-amazon-msk-as-an-event-source-for-lambda/). This metric is different than the existing IteratorAge metric used for Kinesis streams. OffsetLag represents the difference between the last record written to a Kafka topic and the last record that the function's consumer group has processed (note the metric is in # of records, it's not a time metric). See here: https://docs.aws.amazon.com/lambda/latest/dg/monitoring-metrics.html.

Defaulted the monitor to false since it's a new prop and is not widely used.


By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license

…alarm and widget for the Lambda OffsetLag metric

Lambda has added support for connecting to Kafka streams via Event Source Mappings (see: https://docs.aws.amazon.com/lambda/latest/dg/with-msk.html). This comes with the addition of a new CW metric under the AWS/Lambda namespace, `OffsetLag` (see: https://aws.amazon.com/blogs/compute/offset-lag-metric-for-amazon-msk-as-an-event-source-for-lambda/). This metric is different than the existing IteratorAge metric used for Kinesis streams. OffsetLag represents the difference between the last record written to a Kafka topic and the last record that the function's consumer group has processed (note the metric is in # of records, it's not a time metric). See here: https://docs.aws.amazon.com/lambda/latest/dg/monitoring-metrics.html.

Defaulted the monitor to `false` since it's a new prop and is not widely used.
@ghost ghost changed the title feat(lambda): add isOffsetLag prop and add support for generating an … feat(lambda): add isOffsetLag prop for alarms/dashboards for OffsetLag metric Sep 18, 2024
@ghost ghost self-requested a review September 18, 2024 14:56
@ghost ghost merged commit 8e77c25 into cdklabs:main Sep 18, 2024
11 checks passed
mergify bot pushed a commit that referenced this pull request Sep 24, 2024
Fixes regression from #574.

---

_By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license_
This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant