Skip to content

feat(iotevents): add IoT Events input L2 Construct - #17847

Merged
mergify[bot] merged 7 commits into
aws:masterfrom
yamatatsu:iotevents-input
Dec 11, 2021
Merged

mergify[bot] merged 7 commits into
aws:masterfrom
yamatatsu:iotevents-input

Conversation

@yamatatsu

Copy link
Copy Markdown
Contributor

This is proposed by #17711.

This PR was created for implemeting Input L2 Construct. Implementing it is needed before DetectorModel. The reason is described in here: #17711 (comment)


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

@gitpod-io

gitpod-io Bot commented Dec 5, 2021

Copy link
Copy Markdown

@github-actions github-actions Bot added the @aws-cdk/aws-iotevents Related to AWS IoT Events label Dec 5, 2021
@pahud

pahud commented Dec 7, 2021

Copy link
Copy Markdown
Contributor

Hi @minche-tsai are you able to take a first look?

@skinny85 skinny85 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Looks great as always @yamatatsu! A few minor comments.

/**
* The name of the input
*
* @default xxx

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

😃

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

🙇🏻

/**
* Defines an AWS IoT Events input in this stack.
*/
export class Input extends Resource {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Looks like we're missing the IInput interface for Input.

const resource = new CfnInput(this, 'Resource', {
inputName: this.physicalName,
inputDefinition: {
attributes: props.attributeJsonPaths.map(path => ({ jsonPath: path })),

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Can attributeJsonPaths be empty? If not, can we validate that it's not? If it can be empty, can we make it optional, and default to []?

@yamatatsu yamatatsu Dec 8, 2021 •

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

As you said, attributeJsonPaths can not be empty. So I've been thinking that it is better to validate it too!
On the other hand, I thought I had to make my initial L2 PR smaller so as not to repeat my previous mistakes😅 .

I never mind which ways, implement in this PR or after! 😉
I've fixed it!

@mergify
mergify Bot dismissed skinny85’s stale review December 8, 2021 10:18

Pull request has been modified.

@yamatatsu
yamatatsu requested a review from skinny85 December 8, 2021 11:58

@skinny85 skinny85 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Fantastic work @yamatatsu!

skinny85
skinny85 previously approved these changes Dec 10, 2021
@mergify
mergify Bot dismissed skinny85’s stale review December 10, 2021 22:06

Pull request has been modified.

@mergify

mergify Bot commented Dec 10, 2021

Copy link
Copy Markdown
Contributor

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
Copy Markdown
Collaborator

AWS CodeBuild CI Report

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

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

@mergify
mergify Bot merged commit 9f03dc4 into aws:master Dec 11, 2021
@mergify

mergify Bot commented Dec 11, 2021

Copy link
Copy Markdown
Contributor

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).

@yamatatsu
yamatatsu deleted the iotevents-input branch December 14, 2021 13:22
TikiTDO pushed a commit to TikiTDO/aws-cdk that referenced this pull request Feb 21, 2022
This is proposed by aws#17711.

This PR was created for implemeting `Input` L2 Construct. Implementing it is needed before `DetectorModel`. The reason is described in here: aws#17711 (comment)

----

*By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
ali-n4i pushed a commit to ali-n4i/aws-cdk that referenced this pull request Jul 29, 2026
This is proposed by aws#17711.

This PR was created for implemeting `Input` L2 Construct. Implementing it is needed before `DetectorModel`. The reason is described in here: aws#17711 (comment)

----

*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

@aws-cdk/aws-iotevents Related to AWS IoT Events

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants