You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Lots of things in Pulumi use autonaming – a feature whereby Pulumi ensures unique names for “physical” (cloud-side) resources by generating names or name suffixes. For instance, if one uses the AWS provider to write:
constfoo=newaws.rds.Instance("foo",{ ... })
One will end up with an RDS database named (for instance) foo-ab158dc9. The motivations for this feature are several – being able to handle create-before-replace semantics to aid in various zero-downtime scenarios; being able to spin up multiple instances of the same stack into a single account/cloud-side presence; and so on.
If one wants to specify a resource name exactly, this can nearly always be accomplished by explicitly specifying a specific input (rather than relying on the Pulumi resource name). Often this is called name, but this is not always the case; for RDS instances the input is named identifier:
RDS instances also happen to offer an identifierPrefix input which allows some degree of control over names whilst still asking Pulumi to generate parts of the name, but this is specific to this resource. In general, to control naming, users and customers will have to think about this issue for each provider and set of resources they create.
This is not ideal, and many users and customers have wanted broad-spectrum or high-level control over how and when autonaming works for a long time.
Personally i just dont think autonaming works at all. DeleteBeforeReplace should just become the standard behaviour and autonaming scrapped in favour of the name being passed to the constructor being the name used.
The intention is to make that an option, but we have plenty of customers who believe the opposite and we can't safely make a break change like that now anyway.
Lots of things in Pulumi use autonaming – a feature whereby Pulumi ensures unique names for “physical” (cloud-side) resources by generating names or name suffixes. For instance, if one uses the AWS provider to write:
One will end up with an RDS database named (for instance)
foo-ab158dc9
. The motivations for this feature are several – being able to handle create-before-replace semantics to aid in various zero-downtime scenarios; being able to spin up multiple instances of the same stack into a single account/cloud-side presence; and so on.If one wants to specify a resource name exactly, this can nearly always be accomplished by explicitly specifying a specific input (rather than relying on the Pulumi resource name). Often this is called
name
, but this is not always the case; for RDS instances the input is namedidentifier
:RDS instances also happen to offer an
identifierPrefix
input which allows some degree of control over names whilst still asking Pulumi to generate parts of the name, but this is specific to this resource. In general, to control naming, users and customers will have to think about this issue for each provider and set of resources they create.This is not ideal, and many users and customers have wanted broad-spectrum or high-level control over how and when autonaming works for a long time.
Related issues: #1518
Design (M104)
Implementation Plan
TODO
Announce
The text was updated successfully, but these errors were encountered: