-
Notifications
You must be signed in to change notification settings - Fork 4.1k
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
rfc: tree.json #4053
rfc: tree.json #4053
Conversation
Thanks so much for taking the time to contribute to the AWS CDK ❤️ We will shortly assign someone to review this pull request and help get it
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks solid. Clear and concise and describes the benefits well.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See comments
design/construct-tree.md
Outdated
3. ***Metadata -*** Constructs will expose metadata which will include an array of objects associated with the construct. | ||
1. **Location** - The full path of the location where the construct is defined. This will support use cases where the construct-tree nodes can support navigability back to the declaration in the IDE itself. | ||
2. ***Properties*** - Constructs will opt into the set of properties, and these will be exposed. Higher level constructs (L2 and L3) will expose properties and values of the resources they contain and not necessarily enumerate every property that’s available for a resource. This will especially be useful for constructs that are opinionated and set defaults on behalf of developers. Low level constructs (L1) will expose all properties that are configured. | ||
3. ***Errors/Warnings*** - Errors and warnings that are produced during synthesis indicating validation failures, deprecation notices, guidance, etc will be included in the tree. These are emitted at the construct level although the message may point towards a specific property. The construct tree should be complete and include validation failures for all resources in the CDK application rather than just just fail on the first error. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do errors & warnings fall under "minimal set of requirements"?
2. **Constructs** | ||
1. ***Nodes*** - CDK application constructs at the root and drill down to the constructs it contains (1+ cloud resources.) Initially, we will focus our attention on AWS resources, but the model is extensible to cloud components from any provider | ||
2. **Types/Hierarchy** - Types and hierarchy information will contain the details around the level of abstraction (L1, L2, L3..), service(s), and resource(s) that they represent. | ||
3. ***Metadata -*** Constructs will expose metadata which will include an array of objects associated with the construct. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The 'Metadata' group sounds vague and it's not clear why these 3 fall under this but not 'Type'.
I'd suggest dropping this grouping in this requirements section altogether. Perhaps something along the lines of -
"The following information will be exposed for all instances of all CDK constructs, involved in the application. They are (a) Type & hierarchy - ... (b) source location - .... (c) ..."
Would that be better?
1. **Format** - Publish underlying data as a `.json` file that contains the information required to render a construct tree view. The construct tree illustrated in the previous section is only a depiction of what a human readable(ish) view might look like | ||
2. **Constructs** | ||
1. ***Nodes*** - CDK application constructs at the root and drill down to the constructs it contains (1+ cloud resources.) Initially, we will focus our attention on AWS resources, but the model is extensible to cloud components from any provider | ||
2. **Types/Hierarchy** - Types and hierarchy information will contain the details around the level of abstraction (L1, L2, L3..), service(s), and resource(s) that they represent. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure I follow this.
-
Type - Is this the Type of the construct within CDK, or the type of resource (in the case of an L1) this renders into. Which one do we want? I suppose both.
-
What's hierarchy? And what exactly do we want to expose? From what I understand, there are two things here - one is the hierarchy of CDK Construct classes (viz. SingletonLambda → FunctionBase → IFunction) and the other is the hierarchy of how a specific (AWS) Resource got created. They're both valuable to power different experiences.
design/construct-tree.md
Outdated
|--- |--- |--- |--- | | ||
|sourceLocation |string |Required |location in source code where the construct is defined | | ||
|resourceType |string |Required |type of resource (schema / classification terminology TBD) | | ||
|description |string |Not Required |description of the construct | |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
+1 and why is it needed?
Publish the CDK construct hierarchy with the construct id and path to the cloud assembly directory, with a corresponding manifest entry. Motivation and proposal documented in RFC - #4053. This change focuses on integrating generating the metadata into the cloud assembly as part of the the 'synthesize' lifecycle phase. Subsequent changes will enrich the metadata file with additional information from the construct tree (see RFC).
Publish the CDK construct tree with the construct id and path to the cloud assembly directory, with a corresponding manifest entry. Motivation and proposal documented in RFC - #4053. This change focuses on integrating generating the metadata into the cloud assembly as part of the the 'synthesize' lifecycle phase. Subsequent changes will enrich the output with additional information about each construct (see RFC).
AWS CodeBuild CI Report
Powered by github-codebuild-logs, available on the AWS Serverless Application Repository |
…ceholders to describe source of construct properties
…rs to fill in source of metadata
… columns for construct properties
AWS CodeBuild CI Report
Powered by github-codebuild-logs, available on the AWS Serverless Application Repository |
AWS CodeBuild CI Report
Powered by github-codebuild-logs, available on the AWS Serverless Application Repository |
…and properties by naming convention
AWS CodeBuild CI Report
Powered by github-codebuild-logs, available on the AWS Serverless Application Repository |
Thanks so much for taking the time to contribute to the AWS CDK ❤️ We will shortly assign someone to review this pull request and help get it
|
Thanks so much for taking the time to contribute to the AWS CDK ❤️ We will shortly assign someone to review this pull request and help get it
|
Thanks so much for taking the time to contribute to the AWS CDK ❤️ We will shortly assign someone to review this pull request and help get it
|
Thanks so much for taking the time to contribute to the AWS CDK ❤️ We will shortly assign someone to review this pull request and help get it
|
2 similar comments
Thanks so much for taking the time to contribute to the AWS CDK ❤️ We will shortly assign someone to review this pull request and help get it
|
Thanks so much for taking the time to contribute to the AWS CDK ❤️ We will shortly assign someone to review this pull request and help get it
|
Title does not follow the guidelines of Conventional Commits. Please adjust title before merge. |
AWS CodeBuild CI Report
Powered by github-codebuild-logs, available on the AWS Serverless Application Repository |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
looks good go ahead.
please move it to the RFC repo after merge and create a tracking issue following the RFC workflow.
Strategy for publishing the construct tree which represents a CDK app as a part of the Cloud Assembly that the CDK generates.
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license