Socket
Socket
Sign inDemoInstall

@aws-cdk/cloud-assembly-schema

Package Overview
Dependencies
Maintainers
5
Versions
466
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@aws-cdk/cloud-assembly-schema

Cloud Assembly Schema


Version published
Weekly downloads
637K
decreased by-14.41%
Maintainers
5
Weekly downloads
 
Created

Package description

What is @aws-cdk/cloud-assembly-schema?

@aws-cdk/cloud-assembly-schema is a package that defines the schema for AWS Cloud Development Kit (CDK) cloud assemblies. It provides a set of TypeScript interfaces and JSON schemas that describe the structure of the cloud assembly, which is the output of the CDK synthesis process. This package is essential for tools and libraries that need to interact with or manipulate CDK cloud assemblies.

What are @aws-cdk/cloud-assembly-schema's main functionalities?

Cloud Assembly Schema Definition

Defines the schema for a cloud assembly, including the version and artifacts. This schema is used to validate the structure of a cloud assembly JSON file.

{"type":"object","properties":{"version":{"type":"string"},"artifacts":{"type":"object","additionalProperties":{"$ref":"#/definitions/Artifact"}}},"required":["version","artifacts"],"definitions":{"Artifact":{"type":"object","properties":{"type":{"type":"string"},"properties":{"type":"object"}},"required":["type"]}}}

Artifact Type Definitions

Defines the schema for different types of artifacts, such as CloudFormation stacks and CDK assets. This schema is used to validate the structure of artifact definitions within a cloud assembly.

{"type":"object","properties":{"type":{"type":"string","enum":["aws:cloudformation:stack","aws:cdk:asset"]},"properties":{"type":"object","properties":{"templateFile":{"type":"string"},"parameters":{"type":"object","additionalProperties":{"type":"string"}}},"required":["templateFile"]}},"required":["type","properties"]}

Other packages similar to @aws-cdk/cloud-assembly-schema

Changelog

Source

1.135.0 (2021-12-10)

⚠ BREAKING CHANGES TO EXPERIMENTAL FEATURES

  • apigatewayv2-authorizers: The default value for the prop authorizerName in HttpJwtAuthorizerProps has changed.
  • apigatewayv2-authorizers: HttpJwtAuthorizer now takes the construct id and the target jwt issuer as part of its constructor.
  • apigatewayv2-authorizers: HttpLambdaAuthorizer now takes the construct id and the target lambda function handler as part of its constructor.
  • apigatewayv2-authorizers: The default value for the prop authorizerName in HttpUserPoolAuthorizerProps has changed.
  • apigatewayv2: The HttpIntegration and WebSocketIntegration classes require an "id" parameter to be provided during its initialization.
  • apigatewayv2-integrations: The LambdaWebSocketIntegration is now renamed to WebSocketLambdaIntegration. The new class accepts the handler to the target lambda function directly in its constructor.
  • apigatewayv2-integrations: HttpProxyIntegration and HttpProxyIntegrationProps are now renamed to HttpUrlIntegration and HttpUrlIntegrationProps respectively. The new class accepts the target url directly in its constructor.
  • apigatewayv2-integrations: LambdaProxyIntegration and LambdaProxyIntegrationProps are now renamed to HttpLambdaIntegration and HttpLambdaIntegrationProps respectively. The new class accepts the lambda function handler directly in its constructor.
  • apigatewayv2-integrations: HttpAlbIntegration now accepts the ELB listener directly in its constructor.
  • apigatewayv2-integrations: HttpNlbIntegration now accepts the ELB listener directly in its constructor.
  • apigatewayv2-integrations: HttpServiceDiscoveryIntegration now accepts the service discovery Service directly in its constructor.
  • apigatewayv2-authorizers: UserPoolAuthorizerProps is now renamed to HttpUserPoolAuthorizerProps.
  • apigatewayv2: The interface IHttpRouteIntegration is replaced by the abstract class HttpRouteIntegration.
  • apigatewayv2: The interface IWebSocketRouteIntegration is now replaced by the abstract class WebSocketRouteIntegration.
  • apigatewayv2: Previously, we allowed the usage of integration classes to be used with routes defined in multiple HttpApi instances (or WebSocketApi instances). This is now disallowed, and separate instances must be created for each instance of HttpApi or WebSocketApi.

Features

Bug Fixes

  • apigateway: dataTraceEnabled does not default to false (#17906) (cc3bb1f)
  • apigatewayv2: integration class does not render an integration resource (#17729) (3b5b97a), closes #13213
  • apprunner: startCommand and environment are ignored in imageConfiguration (#16939) (d911c58), closes #16812
  • appsync: add caching config to AppSync resolvers (#17815) (52b535b)
  • appsync: empty caching config is created when not provided (#17947) (3a9f206)
  • appsync: remove 'id' suffix to union definition key (#17787) (86e7780), closes #17771
  • assert: support multiline strings with stringLike() (#17692) (37596e6)
  • assets: remove the original-path metadata (#17901) (2b759ca), closes #17706
  • aws-cdk-migration: Construct imports not rewritten (#17931) (f02fcb4), closes #17826
  • aws-ec2: imported VPC subnets never recognized as PRIVATE_ISOLATED (#17496) (ba6a8ef)
  • aws-elasticloadbalancingv2: Set stickiness.enabled unless target type is lambda (#17271) (168a98f), closes #17261
  • cli: S3 asset uploads are rejected by commonly referenced encryption SCP (introduces bootstrap stack v9) (#17668) (8191f1f), closes #11265
  • codepipeline: cannot trigger on all tags anymore in EcrSourceAction (#17270) (39fe11b), closes aws#13818 aws#13818
  • codepipeline: cross-env pipeline cannot be created in Stage (#17730) (f17f29e), closes #17643
  • codepipeline: default cross-region S3 buckets allow public access (#17722) (0b80db5), closes #16411
  • cognito: remove invalid SES region check (#17868) (450f7ca), closes #17795
  • core: bundling skipped with --exclusively option and stacks under stage (#17210) (cda6601), closes #12898 #15346
  • docdb: secret rotation ignores excluded characters in password (#17609) (1fe2215), closes #17347 #17575
  • dynamodb: add missing DynamoDB operations to enum (#17738) (f38e0ac)
  • dynamodb: changing waitForReplicationToFinish fails deployment (#17842) (36b8fdb), closes #16983
  • iam: AWS Managed Policy ARNs are not deduped (#17623) (ed4a4b4), closes #17552
  • lambda-nodejs: bundling fails with a file dependency in nodeModules (#17851) (5737c33), closes #17830
  • lambda-nodejs: bundling with nodeModules fails with paths containing spaces (#17632) (986f291), closes #17631
  • pipelines: stack outputs used in stackSteps not recognized (#17311) (5e4a219), closes #17272
  • s3-deployment: updating memoryLimit or vpc results in stack update failure (#17530) (2ba40d1), closes #7128
  • stepfunctions: prefixes not appended to states in parallel branches (#17806) (a1da772), closes #17354

Miscellaneous Chores

  • apigatewayv2: integration api re-organization (#17752) (29039e8)
  • apigatewayv2-authorizers: re-organize authorizer api (#17772) (719f33e)

Readme

Source

Cloud Assembly Schema


cdk-constructs: Stable


This module is part of the AWS Cloud Development Kit project.

Cloud Assembly

The Cloud Assembly is the output of the synthesis operation. It is produced as part of the cdk synth command, or the app.synth() method invocation.

Its essentially a set of files and directories, one of which is the manifest.json file. It defines the set of instructions that are needed in order to deploy the assembly directory.

For example, when cdk deploy is executed, the CLI reads this file and performs its instructions:

  • Build container images.
  • Upload assets.
  • Deploy CloudFormation templates.

Therefore, the assembly is how the CDK class library and CDK CLI (or any other consumer) communicate. To ensure compatibility between the assembly and its consumers, we treat the manifest file as a well defined, versioned schema.

Schema

This module contains the typescript structs that comprise the manifest.json file, as well as the generated json-schema.

Versioning

The schema version is specified in the cloud-assembly.version.json file, under the version property. It follows semantic versioning, but with a small twist.

When we add instructions to the assembly, they are reflected in the manifest file and the json-schema accordingly. Every such instruction, is crucial for ensuring the correct deployment behavior. This means that to properly deploy a cloud assembly, consumers must be aware of every such instruction modification.

For this reason, every change to the schema, even though it might not strictly break validation of the json-schema format, is considered major version bump.

How to consume

If you'd like to consume the schema file in order to do validations on manifest.json files, simply download it from this repo and run it against standard json-schema validators, such as jsonschema.

Consumers must take into account the major version of the schema they are consuming. They should reject cloud assemblies with a major version that is higher than what they expect. While schema validation might pass on such assemblies, the deployment integrity cannot be guaranteed because some instructions will be ignored.

For example, if your consumer was built when the schema version was 2.0.0, you should reject deploying cloud assemblies with a manifest version of 3.0.0.

Contributing

See Contribution Guide

Keywords

FAQs

Package last updated on 10 Dec 2021

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc