feat(kinesisfirehose-alpha): refactor sourceStream property to support multiple types of sources#31723
Conversation
…t multiple types of sources
aws-cdk-automation
left a comment
There was a problem hiding this comment.
The pull request linter has failed. See the aws-cdk-automation comment below for failure reasons. If you believe this pull request should receive an exemption, please comment and provide a justification.
A comment requesting an exemption should contain the text Exemption Request. Additionally, if clarification is needed add Clarification Request to a comment.
✅ Updated pull request passes all PRLinter validations. Dismissing previous PRLinter review.
Leo10Gama
left a comment
There was a problem hiding this comment.
Overall looks good, just a few nits and a few clarifications on some of the new implementation
Co-authored-by: Leonardo Gama <51037424+Leo10Gama@users.noreply.github.com>
Co-authored-by: Leonardo Gama <51037424+Leo10Gama@users.noreply.github.com>
|
Thank you for contributing! Your pull request will be updated from main and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork). |
|
@Mergifyio update |
❌ Mergify doesn't have permission to updateDetailsFor security reasons, Mergify can't update this pull request. Try updating locally. |
|
Thank you for contributing! Your pull request will be updated from main and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork). |
AWS CodeBuild CI Report
Powered by github-codebuild-logs, available on the AWS Serverless Application Repository |
|
Thank you for contributing! Your pull request will be updated from main and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork). |
|
Comments on closed issues and PRs are hard for our team to see. |
Reason for this change
The previous API for
sourcewas designed under the assumption that a Source would either be aStreamorDirect Putif not. Since the alpha module was written, support on the service side for MSK as a Source has been added so we should update thesourceproperty to accept anISourcewhich can then be implemented by different types of Sources.Description of changes
Replaced the
sourceStreamproperty withsource.Changed the
sourceproperty fromIStreamtoISource.Added an
ISourceinterface which is implemented by classes which represent the different Source types. Currently implemented by theKinesisStreamSourceclass. TheMSKSourceclass can be added in a separate PR.Added a
SourceConfigwhich contains the property configs for each respective source (as the fields within these property configs are different across each source). Indelivery-stream.tswe call the_bindmethod which will populate and return the correct property config for the Source and that gets directly injected where the L1CFNDeliveryStreamis created. This pattern is also used for Destinations:Description of how you validated changes
no behavioural changes. the updated integ tests and unit tests still pass existing tests.
exempting integ tests because we don't want the generated CFN to change.
Checklist
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license
BREAKING CHANGE: Replaced the
sourceStreamproperty withsource. Changed thesourceproperty type fromIStreamtoISource. Instead of passing in the source Stream directly, it will be passed in by calling the appropriate class like so:source: new source.KinesisStreamSource(sourceStream).