feat: Customizable Kinesis Data Stream Autoscaling#27
Merged
Conversation
julieagnessparks
approved these changes
Sep 27, 2022
shellcromancer
approved these changes
Sep 27, 2022
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Motivation and Context
We manage some KDS that require more aggressive autoscaling settings than others. The two stream behaviors we've observed are:
The latter behavior requires customizable CloudWatch alarms, so to provide that this PR gives users the ability to override the number of datapoints that will trigger a scaling event.
There are several parameters that could be tuned, but focusing on datapoints keeps the configuration simple and still addresses the majority of scaling use cases (i.e., independently scale up or down quickly or slowly).
This also introduces the ability for users to deploy multiple autoscaling Lambda that address different scaling patterns. For example, 80% of data pipelines may use a "steady rate" autoscaling pattern and 20% of data pipelines may use a "burst rate" autoscaling pattern. This can all be managed via Terraform.
Included is a breaking change that removes support for the autoscaling configuration file and replaces it with Kinesis tags. Using tags reduces the amount of configurations that teams need to manage, and since the config was directly impacting Kinesis resources, I think it makes more sense to pair it with the resource in Terraform.
How Has This Been Tested?
Changes tested in production with dozens of data pipelines that have variable stream utilization -- some have very high volume, unpredictable traffic and we haven't observed any issues.
Types of changes
Checklist: