pulumi-ai
pulumi-ai copied to clipboard
[AI Answers] What is the process to cause a delay during resource creation in code in C#
Affected page: What is the process to cause a delay during resource creation in code in C#
This page is advising the use of C# Task.Delay
to introduce a delay during resource creation.
That advice seems bad, because it will create an indiscriminate delay whenever a stack operation such as preview
or up
is performed (and even when nothing needs to change).
Since Pulumi already has the Pulumiverse.Time
provider for this purpose, this would be the more correct answer (it allows the sleep to be specified on resource creation, resource destruction, or both, and will only apply at those points in the resource lifecycle).