npm @serverless-stack/cli 0.59.0
v0.59.0

latest releases: 1.18.4, 1.18.3, 1.18.2...
2 years ago

💥 Breaking Change: Updating to CDK v2

We migrated to CDK v2. Here is how to update your apps.

Estimated time: 15 minutes

Prerequisites

  • Update Node.js to v14 or later
  • Update SST to v0.57.0 or later

Steps

  1. Run npx sst update 0.59.1

  2. Open up your package.json and update CDK dependencies to v2.

    1. If you have @aws-cdk/core as a dependency, rename it to aws-cdk-lib.
    2. If you have @aws-cdk/assert as a dependency, remove it from your package.json.
    3. If you have one or more @aws-cdk/aws-XXXX dependencies, and if they are on the experimental package list below, rename them to @aws-cdk/aws-XXXX-alpha. For example, rename @aws-cdk/api-gatewayv2 to @aws-cdk/api-gatewayv2-alpha.
    4. If you have one or more @aws-cdk/aws-XXXX dependencies, and if they are not on the experimental package list below, remove them from your package.json.
  3. Update the import in your CDK code to use v2 dependencies.

    1. If you import @aws-cdk/core, rename import * as cdk from "@aws-cdk/core" to import * as cdk from "aws-cdk-lib".
    2. If you import @aws-cdk/assert, rename import * as assert from "@aws-cdk/assert" to import * as assert from "aws-cdk-lib/assertions". Read more about using assertions here.
    3. If you import @aws-cdk/aws-XXXX, and if they are on the experimental package list below, rename import * as XXXX from "@aws-cdk/aws-XXXX" to import * as XXXX from "@aws-cdk/aws-XXXX-alpha". For example, rename import * as apig from "@aws-cdk/aws-apigatewayv2" to import * as apig from "@aws-cdk/aws-apigatewayv2-alpha".
    4. If you have one or more @aws-cdk/aws-XXXX dependencies, and if they are not on the experimental package list below, rename import * as XXXX from "@aws-cdk/aws-XXXX" to import * as XXXX from "aws-cdk-lib/aws-XXXX". For example, rename import * as sns from "@aws-cdk/aws-sns" to import * as sns from "aws-cdk-lib/aws-sns".
  4. Run npx sst update 0.59.1 one more time.

  5. Run npx sst diff to review the changes. If you are updating from SST v0.57.0 or later, the only major change is how CDK v2 handles CloudFormation parameters, which mostly affects AWS::Lambda::Function resources' Code properties.

Read more about updating to AWS CDK v2 here

Experimental packages

@aws-cdk/aws-amplify
@aws-cdk/aws-apigatewayv2
@aws-cdk/aws-apigatewayv2-authorizers
@aws-cdk/aws-apigatewayv2-integrations
@aws-cdk/aws-apprunner
@aws-cdk/aws-appsync
@aws-cdk/aws-batch
@aws-cdk/aws-cloud9
@aws-cdk/aws-codestar
@aws-cdk/aws-glue
@aws-cdk/aws-iot-actions
@aws-cdk/aws-iot
@aws-cdk/aws-iotevents
@aws-cdk/aws-ivs
@aws-cdk/aws-kinesisanalytics-flink
@aws-cdk/aws-kinesisfirehose
@aws-cdk/aws-kinesisfirehose-destinations
@aws-cdk/aws-lambda-go
@aws-cdk/aws-lambda-python
@aws-cdk/aws-msk
@aws-cdk/aws-neptune
@aws-cdk/aws-redshift
@aws-cdk/aws-route53resolver
@aws-cdk/aws-servicecatalog
@aws-cdk/aws-servicecatalogappregistry
@aws-cdk/aws-synthetics

🚀 Enhancement

🐛 Bug Fix

  • #1252 Do not do anything special for Go directory handlers (@thdxr)

Don't miss a new cli release

NewReleases is sending notifications on new releases.