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

feat(aws-kinesisfirehose): DeliveryStream API and basic S3 destination #15544

Merged
merged 58 commits into from
Jul 23, 2021

Conversation

madeline-k
Copy link
Contributor

This PR implements the minimum DeliveryStream API and S3 destination.

More features for DeliveryStream and the S3 destination will follow in future PRs. This work is being tracked in https://github.com/aws/aws-cdk/milestone/16

For more context, see: #15505 and the RFC: aws/aws-cdk-rfcs#342

closes #10810, #15499


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

@gitpod-io
Copy link

gitpod-io bot commented Jul 14, 2021

Copy link
Contributor

@skinny85 skinny85 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great! Pretty big, but I understand why you did it this way 😉.

Some comments for the first pass.

packages/@aws-cdk/aws-ec2/lib/connections.ts Show resolved Hide resolved
packages/@aws-cdk/aws-kinesisfirehose/lib/destination.ts Outdated Show resolved Hide resolved
packages/@aws-cdk/aws-kinesisfirehose/lib/destination.ts Outdated Show resolved Hide resolved
packages/@aws-cdk/aws-kinesisfirehose/package.json Outdated Show resolved Hide resolved
deliveryStreamType: 'DirectPut',
...destinationConfig.properties,
});
resource.node.addDependency(this.grantPrincipal);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is also probably not what you want. You're probably looking to take a dependency on a particular grant, not on all grants every done to this principal. The grants have an API for doing exactly that.

packages/@aws-cdk/aws-kinesisfirehose/lib/destination.ts Outdated Show resolved Hide resolved
skinny85
skinny85 previously approved these changes Jul 22, 2021
Copy link
Contributor

@skinny85 skinny85 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks absolutely fantastic 🔥. Amazing work @BenChaimberg @madeline-k and @otaviomacedo!

A few minor optional comments if you're interested.

});

it('creates a role when none is provided', () => {
const capturedRoleArn = Capture.aString();
Copy link
Contributor

@skinny85 skinny85 Jul 22, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would actually put the logical ID of the Role directly in the test. I understand it will be an ugly, hashed logical ID. But I think that's good: in general, you want the tests to act as a guard to make sure the logical IDs of elements in the template you generate are stable while you're doing refactorings (it's easy to change them when changing the construct tree when refactoring).

I understand changing this ID in theory would not be a breaking change, because Roles are stateless, but in my opinion you should be forced to update the unit tests when that happens (in other words, this should be a conscious decision, not something that happens accidentally).

Same comment applies to the tests below.

@skinny85 skinny85 added the pr/do-not-merge This PR should not be merged at this time. label Jul 22, 2021
Co-authored-by: Adam Ruka <adamruka@amazon.com>
@madeline-k madeline-k added contribution/core This is a PR that came from AWS. and removed contribution/core This is a PR that came from AWS. labels Jul 22, 2021
@BenChaimberg BenChaimberg removed the pr/do-not-merge This PR should not be merged at this time. label Jul 23, 2021
@mergify mergify bot merged commit 1b5d525 into master Jul 23, 2021
@mergify mergify bot deleted the madeline-k/feat/kinesisfirehose-deliverystream branch July 23, 2021 00:33
@mergify
Copy link
Contributor

mergify bot commented Jul 23, 2021

Thank you for contributing! Your pull request will be updated from master and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork).

@aws-cdk-automation
Copy link
Collaborator

AWS CodeBuild CI Report

  • CodeBuild project: AutoBuildProject89A8053A-LhjRyN9kxr8o
  • Commit ID: efb6eee
  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

TikiTDO pushed a commit to TikiTDO/aws-cdk that referenced this pull request Aug 3, 2021
aws#15544)

This PR implements the minimum DeliveryStream API and S3 destination.  

More features for DeliveryStream and the S3 destination will follow in future PRs. This work is being tracked in https://github.com/aws/aws-cdk/milestone/16 

For more context, see: aws#15505 and the RFC: aws/aws-cdk-rfcs#342 

closes aws#10810, aws#15499

----

*By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
hollanddd pushed a commit to hollanddd/aws-cdk that referenced this pull request Aug 26, 2021
aws#15544)

This PR implements the minimum DeliveryStream API and S3 destination.  

More features for DeliveryStream and the S3 destination will follow in future PRs. This work is being tracked in https://github.com/aws/aws-cdk/milestone/16 

For more context, see: aws#15505 and the RFC: aws/aws-cdk-rfcs#342 

closes aws#10810, aws#15499

----

*By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
contribution/core This is a PR that came from AWS.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

(kinesisfirehose): L2 for CfnDeliveryStream
5 participants