Skip to content
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

(aws-ssm): valueFromLookup should have an option to skip context caching #12366

Open
2 tasks
cynicaljoy opened this issue Jan 6, 2021 · 6 comments · May be fixed by #29372
Open
2 tasks

(aws-ssm): valueFromLookup should have an option to skip context caching #12366

cynicaljoy opened this issue Jan 6, 2021 · 6 comments · May be fixed by #29372
Labels
@aws-cdk/aws-ssm Related to AWS Systems Manager effort/medium Medium work item – several days of effort feature-request A feature should be added or improved. p2

Comments

@cynicaljoy
Copy link

cynicaljoy commented Jan 6, 2021

When using ssm.StringParameter.valueFromLookup() I would like to have the option to not store the value of the parameter in the cdk context so the parameter is resolved every time that I synth.

Use Case

In particular, I store the value of which ECR Image Tag should be deployed in my Task Definition for my Fargate Service. Currently, if I forget to cdk context --reset ... then I can potentially deploy a previous version of the application. If I was able to skip storing the value in the context I would not have to manage this risk.

Proposed Solution

ssm.StringParameter.valueFromLookup(this, '/my/ssm/parameter', { skipContext: true });
  • 👋 I may be able to implement this feature request
  • ⚠️ This feature might incur a breaking change

This is a 🚀 Feature Request

@cynicaljoy cynicaljoy added feature-request A feature should be added or improved. needs-triage This issue or PR still needs to be triaged. labels Jan 6, 2021
@mrpackethead
Copy link

There may in fact be many cases where it might be useful to have this option. not just for ssm lookups but any context lookup

@NGL321 NGL321 changed the title [aws-ssm]: valueFromLookup should have an option to skip context caching (aws-ssm): valueFromLookup should have an option to skip context caching Feb 1, 2021
@github-actions github-actions bot added the @aws-cdk/aws-ssm Related to AWS Systems Manager label Feb 1, 2021
@MrArnoldPalmer MrArnoldPalmer added effort/medium Medium work item – several days of effort p2 and removed needs-triage This issue or PR still needs to be triaged. labels May 17, 2021
@MrArnoldPalmer MrArnoldPalmer removed their assignment Jun 21, 2021
@wr-cdargis
Copy link

The workaround I've been using is to build the reset into the CI/CD pipeline:

Synth = new ShellStep("Synth", new ShellStepProps
{
    InstallCommands = new[]
    {
        "npm install -g aws-cdk"
    },
    Commands = new[]
    {
        "cdk context --reset key"
    }
})

@github-actions github-actions bot added p1 and removed p2 labels Dec 11, 2022
@github-actions
Copy link

This issue has received a significant amount of attention so we are automatically upgrading its priority. A member of the community will see the re-prioritization and provide an update on the issue.

@mixtah
Copy link

mixtah commented Jun 8, 2023

I have a similar use case and want to know if this is being explored any time soon?

@gautamdevendra
Copy link

any progress? similar issue here

@andreialecu
Copy link
Contributor

PR at #29372 to add this

@pahud pahud added p2 and removed p1 labels Jun 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
@aws-cdk/aws-ssm Related to AWS Systems Manager effort/medium Medium work item – several days of effort feature-request A feature should be added or improved. p2
Projects
None yet
Development

Successfully merging a pull request may close this issue.

8 participants