Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: aws/aws-cdk-cli
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: [email protected]
Choose a base ref
...
head repository: aws/aws-cdk-cli
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: [email protected]
Choose a head ref
  • 5 commits
  • 21 files changed
  • 3 contributors

Commits on May 29, 2025

  1. fix(toolkit-lib): stack definitions for refactor are not considering …

    …resource refrences (#547)
    
    The `createStackRefactor` method, from the CloudFormation API, requires
    the client to pass not only the mappings, but also the templates in the
    state they are supposed to be after the refactor.
    
    Previously, this was done by iterating over the mappings (either
    computed by the toolkit or prescribed by the user), and using them as a
    list of instructions on how to modify the deployed stacks, moving
    resources around as necessary. This is a simple way to put the resources
    in their correct locations. But it becomes unwieldy when it comes to
    updating references between resources. Every time a resource is moved,
    all references to it -- and sometimes from it -- have to be updated as
    well.
    
    This PR changes implements a different algorithm: take all the
    synthesized templates as a starting point, and adjust them so that the
    final templates are equal to the deployed ones up to logical IDs and
    references. The result is what will be sent to CloudFormation.
    Specifically this involves:
    
    - Removing resources that exist locally but not remotely.
    - Adding resources that exist remotely but not locally.
    - Update the CDK construct path to the deployed value. (we will drop
    this once CloudFormation starts allowing changes in the construct path
    along with refactors).
    
    One case that is not yet covered is when physical IDs are set. Because
    we use the physical ID plus the type of the resource to identify it,
    users are free to change other properties, and we can still recognize
    that it's the same resource. Since we are simply taking the local
    resource as the basis and not updating anything other than the construct
    path, it's possible that it differs from the deployed one. This case
    will be handled in a following PR.
    
    ---
    By submitting this pull request, I confirm that my contribution is made
    under the terms of the Apache-2.0 license
    otaviomacedo authored May 29, 2025
    Configuration menu
    Copy the full SHA
    29a724a View commit details
    Browse the repository at this point in the history
  2. chore: document atmosphere usage during PR builds (#551)

    Outline the reasons why a PR may pass locally, but fail during PR build.
    
    ---
    By submitting this pull request, I confirm that my contribution is made
    under the terms of the Apache-2.0 license
    iliapolo authored May 29, 2025
    Configuration menu
    Copy the full SHA
    c404f17 View commit details
    Browse the repository at this point in the history
  3. feat(toolkit-lib): General Availability of the AWS CDK Toolkit Library (

    #553)
    
    **📣 Today we are very happy to announce the General Availability of the
    AWS CDK Toolkit Library 📣**
    
    The AWS Cloud Development Kit (AWS CDK) Toolkit Library enables you to
    perform CDK actions requiring programmatic access on AWS. You can use
    the AWS CDK Toolkit Library to implement actions such as bootstrapping,
    synthesizing, and deploying through code rather than command-line
    interface (CLI) commands. With this library, you can create custom
    tools, build specialized CLI applications, and integrate CDK
    programmatic access capabilities into your development workflows.
    
    📜 Reference documentation:
    https://docs.aws.amazon.com/cdk/api/toolkit-lib/
    📦  npm package: https://www.npmjs.com/package/@aws-cdk/toolkit-lib
    👩🏻‍🏫 Guide:
    https://docs.aws.amazon.com/cdk/v2/guide/toolkit-library.html
    
    ---
    
    Even though the CDK Toolkit Library is now *generally available*, we
    still want to hear from you and appreciate all feedback!
    
    💬 [Provide feedback, ideas and request new
    features](#154)
    🐛  [Report a bug](https://github.com/aws/aws-cdk-cli/issues/new/choose)
    
    ---
    By submitting this pull request, I confirm that my contribution is made
    under the terms of the Apache-2.0 license
    mrgrain authored May 29, 2025
    Configuration menu
    Copy the full SHA
    dda5e82 View commit details
    Browse the repository at this point in the history
  4. fix(cloud-assembly-schema): CcApiContextQuery does not compile with…

    … `jsii-rosetta` (#554)
    
    Fixed the `CcApiContextQuery` to compile with jsii-rosetta. Added the
    previously missing build steps to ensure all examples compile.
    
    ---
    By submitting this pull request, I confirm that my contribution is made
    under the terms of the Apache-2.0 license
    mrgrain authored May 29, 2025
    Configuration menu
    Copy the full SHA
    4d467ca View commit details
    Browse the repository at this point in the history
  5. fix(toolkit-lib): drift detection options are unnecessarily required (#…

    …552)
    
    ## Description
    
    This PR improves the drift detection implementation in the CDK
    toolkit-lib by making the 'stacks' parameter optional in the
    DriftOptions interface and providing default options in the
    toolkit.drift() method. These changes enhance the API's usability and
    consistency.
    
    ### Changes:
    
    1. Made 'stacks' parameter optional in DriftOptions interface
    2. Added default empty options object to toolkit.drift() method
    3. Added a test case to verify that drift action can be invoked without
    options
    
    These changes make the drift detection API more flexible and consistent
    with other toolkit methods that typically provide default options.
    
    ---
    By submitting this pull request, I confirm that my contribution is made
    under the terms of the Apache-2.0 license
    mrgrain authored May 29, 2025
    Configuration menu
    Copy the full SHA
    60506e5 View commit details
    Browse the repository at this point in the history
Loading