An engineer is about to change the name property of a resource in an "AWS CloudFormation" stack and knows from experience that some property changes force CloudFormation to replace the resource by creating a new one and deleting the old. Before running the update on a production stack, the engineer wants the pipeline to reveal exactly which resources would be replaced so a risky change can be caught in review. Which mechanism MOST directly surfaces the replacement impact ahead of time?
- ARun drift detection on the stack first so the report identifies which resources the pending update is going to replace once it runs.
- BCreate a change set for the proposed update and inspect its "Replacement" field, which marks each resource that the update would replace before any change is applied. Correct
- CAdd an "UpdateReplacePolicy" of "Retain" to the resource so that the pipeline lists every resource that would be replaced when the update runs.
- DValidate the template with the validate-template operation so the pipeline returns the list of resources that the update would need to replace.
Why A is wrong: Drift detection compares live resources to the currently deployed template, not to a proposed new template, so it reveals existing drift rather than the replacements a future update would cause.
Why B is correct: A change set computes the resource-level diff against the live stack, including a Replacement value of True for resources that an update would recreate, so reviewers see the exact replacement impact before execution.
Why C is wrong: UpdateReplacePolicy only decides whether the old resource is kept or deleted when a replacement happens; it changes the outcome of replacement but does not preview which resources will be replaced.
Why D is wrong: Template validation only checks structural correctness and parameter declarations; it has no view of the deployed stack, so it cannot determine which resources an update would replace.