the parameter group was created when pulumi
# python
h
the parameter group was created when pulumi
w
Did you change the logical name of the resource in your Pulumi code? This would cause Pulumi to think it needs to create a new one and delete the old one. (the logical name is how Pulumi tracks identity across deployments)
That is
aws.rds.ParameterGroup(logicalName, { name: physicalName })
.
h
hmm i have code in python module and did not change resource name
i do self.name + “paramater group”
let me look at details
w
What does your preview show?
h
looking
Copy code
pulumi:pulumi:Stack: (same)
    [urn=urn:pulumi:test::test::pulumi:pulumi:Stack::test-test]
        + aws:rds/parameterGroup:ParameterGroup: (create)
            [urn=urn:pulumi:test::test::mahana-python:snorkelfargateapp:MahanaFargateApp$aws:rds/parameterGroup:ParameterGroup::testdevapptest]
            [provider=urn:pulumi:test::test::pulumi:providers:aws::default_1_7_0::4910d117-d2d7-4356-83a3-4e4c7694b51a]
            description: "Managed by Pulumi"
            family     : "postgres9.6"
            name       : "testdevapprdsparameters"
            parameters : [
                [0]: {
                    applyMethod: "pending-reboot"
                    name       : "rds.force_ssl"
                    value      : "0"
                }
            ]
Copy code
- aws:rds/parameterGroup:ParameterGroup: (delete)
        [id=testrdsparameters]
        [urn=urn:pulumi:test::test::aws:rds/parameterGroup:ParameterGroup::test]
        [provider=urn:pulumi:test::test::pulumi:providers:aws::default_1_8_0::de9a190f-2958-4411-a5e8-fd8a3a52bfc0]
        --aws:ecs/taskDefinition:TaskDefinition: (delete-replaced)
            [id=testdevappfargate-task]
            [urn=urn:pulumi:test::test::mahana-python:snorkelfargateapp:MahanaFargateApp$aws:ecs/taskDefinition:TaskDefinition::testdevappapp-task]
            [provider=urn:pulumi:test::test::pulumi:providers:aws::default_1_8_0::de9a190f-2958-4411-a5e8-fd8a3a52bfc0]
    - aws:rds/parameterGroup:ParameterGroup: (delete)
        [id=testdevapprdsparameters]
        [urn=urn:pulumi:test::test::aws:rds/parameterGroup:ParameterGroup::testdevapptest]
        [provider=urn:pulumi:test::test::pulumi:providers:aws::default_1_8_0::de9a190f-2958-4411-a5e8-fd8a3a52bfc0]
let me check the name in the ui
w
Yeah - it looks like you are changing the URN from: •
urn:pulumi:test::test::aws:rds/parameterGroup:ParameterGroup::test
urn:pulumi:test::test::mahana-python:snorkelfargateapp:MahanaFargateApp$aws:rds/parameterGroup:ParameterGroup::testdevapptest
Are you moving it inside a component?
Pulumi thinks these are two unrelated resources since their URNs are different - so creates the latter and deletes the former. You can use
aliases
to tell Pulumi these are two different names for the same thing. https://www.pulumi.com/docs/intro/concepts/programming-model/#aliases
h
kk i will take a look
Thank you this helped
Copy code
Provides a list of aliases for a resource or component. When making a breaking change to the name or type of a resource or component, you can add the old name to the list of aliases for a resource to ensure that existing resources will be migrated to the new name instead of being deleted and replaced with the new named resource.
This is also probably why new congnito pool was getting created when i was adding new attributes to existing congnito user pool