Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

KinesisBackend.put_record should notify cloudwatch metrics #7498

Open
LMaterne opened this issue Mar 20, 2024 · 2 comments
Open

KinesisBackend.put_record should notify cloudwatch metrics #7498

LMaterne opened this issue Mar 20, 2024 · 2 comments

Comments

@LMaterne
Copy link
Contributor

def put_record(
should include some update to cloudwatch metrics at least for the IncomingRecords and IncomingBytes Basic Stream-level Metrics.

@bblommers
Copy link
Collaborator

Hi @LMaterne, I'll mark it as an enhancement.

Can you elaborate a bit on what your test would look like?

The docs specifically mention that The metrics [..] are pushed to CloudWatch every minute., but that approach doesn't make a lot of sense for unit tests, as (I hope that) they don't run for that long.

I can think of a few approaches around this, but having some insight into how this feature would be used would be helpful to make sure that the solution makes sense.

@LMaterne
Copy link
Contributor Author

LMaterne commented Apr 1, 2024

My concrete test case looks like this: I want to test a lambda function that scales the number of shard counts in provisioned kinesis streams based on the amount of incoming traffic. The logic uses the stream metrics for that. The integration test would look like putting some messages into a newly created kinesis stream and checking if the lambda function scales the stream correctly. My current solution: Do not put records into the stream but directly update the cloudwatch metrics.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants