McAfee-Secured Website

Exam Bundle

Exam Code: Terraform Associate 004

Exam Name HashiCorp Certified: Terraform Associate (004)

Certification Provider: HashiCorp

Corresponding Certification: Terraform Associate

HashiCorp Terraform Associate 004 Bundle $19.99

100% HashiCorp Terraform Associate 004 Guaranteed Success With Testking Training Materials

Get Real Terraform Associate 004 Exam Questions & Expert Verified Answers as Experienced on the Real Exam!

  • Questions & Answers

    Terraform Associate 004 Questions & Answers

    167 Questions & Answers

    The ultimate exam preparation tool, Questions & Answers mirrors the actual Terraform Associate 004 exam while allowing you to hone and measure every aspect of your test-taking ability.

  • Study Guide

    Terraform Associate 004 Study Guide

    285 PDF Pages

    Developed by industry experts, this 285-page guide spells out in painstaking detail all of the information you need to ace Terraform Associate 004 exam.

HashiCorp Certified: Terraform Associate (004) (Terraform Associate 004) Practice Tests

Satisfaction Guaranteed

Money Back Guarantee

Testking provides hassle-free money back guarantee with our products. That is because we have 100% trust in the abilities of our professional and experience product team, and our record is a proof of that.

99.6% PASS RATE
Total Cost: $154.98
Bundle Price: $134.99

Purchase Individually

  • Questions & Answers

    Questions & Answers

    167 Questions

    $124.99
  • Study Guide

    Study Guide

    285 PDF Pages

    $29.99

HashiCorp Terraform Associate 004 Practice Test 22

Question 210

The Terraform change owner at Lakeview Data Services seeks a verifiable outcome for: A team expects terraform validate to confirm current cloud permissions and guaranteed sufficient quotas. Which observation best confirms that the proposed correction worked?

  1. The default local run produces a local state file while the configured shared run reads the expected remote state instead.
  2. Validation passes syntactically while a deliberately revoked permission is detected during a controlled live operation.
  3. The CI decision distinguishes a legitimate diff from a genuine planning error without skipping review.
  4. The bucket is tracked by one responsible state and downstream plans do not fight over its settings.

Explanation

Correct Answer

B:

Validation passes syntactically while a deliberately revoked permission is detected during a controlled live operation. This directly verifies the corrective action: Use validate for static configuration checks and use planning or purpose-built deployment tests for live API constraints. The measured result specifically addresses the failure at Lakeview Data Services: A team expects terraform validate to confirm current cloud permissions and guaranteed sufficient quotas.

Incorrect Answers

A:

The default local run produces a local state file while the configured shared run reads the expected remote state instead. This evidence would validate a DIFFERENT correction: Identify the default local backend behavior and explicitly configure a suitable shared backend when collaboration is required. That different correction addresses: A new Terraform root module writes terraform.tfstate to the developer's laptop but its team assumes state is already centrally shared. It does not establish that the Lakeview Data Services issue has been corrected: A team expects terraform validate to confirm current cloud permissions and guaranteed sufficient quotas. The relevant measured outcome is: Validation passes syntactically while a deliberately revoked permission is detected during a controlled live operation.

C:

The CI decision distinguishes a legitimate diff from a genuine planning error without skipping review. This evidence would validate a DIFFERENT correction: Handle the documented detailed exit codes: zero for no changes, two for changes, and one for errors. That different correction addresses: A CI job invokes terraform plan -detailed-exitcode but treats a change-detected exit status as a tool failure. It does not establish that the Lakeview Data Services issue has been corrected: A team expects terraform validate to confirm current cloud permissions and guaranteed sufficient quotas. The relevant measured outcome is: Validation passes syntactically while a deliberately revoked permission is detected during a controlled live operation.

D:

The bucket is tracked by one responsible state and downstream plans do not fight over its settings. This evidence would validate a DIFFERENT correction: Assign a single owner state for the object and let other teams consume its outputs or a read-only lookup. That different correction addresses: An operator imports the same remote bucket into two independent root states to share responsibility between teams. It does not establish that the Lakeview Data Services issue has been corrected: A team expects terraform validate to confirm current cloud permissions and guaranteed sufficient quotas. The relevant measured outcome is: Validation passes syntactically while a deliberately revoked permission is detected during a controlled live operation.

Question 211

During repository review at Atlas Platform Services, the platform team reports: A team expects terraform validate to confirm current cloud permissions and guaranteed sufficient quotas. Which proposed fix addresses the reported root cause?

  1. Version Terraform configuration and associate reviewed plan/application records with release changes.
  2. Set TF_LOG to a needed diagnostic level for a controlled run and protect or redact any captured output.
  3. Use validate for static configuration checks and use planning or purpose-built deployment tests for live API constraints.
  4. Run terraform plan and examine create/update/delete or replace actions, not just the source diff.

Explanation

Correct Answer

C:

Use validate for static configuration checks and use planning or purpose-built deployment tests for live API constraints. This is targeted to the observed Terraform issue: A team expects terraform validate to confirm current cloud permissions and guaranteed sufficient quotas. At Atlas Platform Services, the acceptance criterion is not merely a valid plan; the team should verify: Validation passes syntactically while a deliberately revoked permission is detected during a controlled live operation.

Incorrect Answers

A:

Version Terraform configuration and associate reviewed plan/application records with release changes. This would be suitable for a DIFFERENT Terraform problem: A product deployment has no record of when a gateway size was changed, making regression analysis difficult. It does not directly resolve the Atlas Platform Services failure: A team expects terraform validate to confirm current cloud permissions and guaranteed sufficient quotas. The required acceptance evidence instead is: Validation passes syntactically while a deliberately revoked permission is detected during a controlled live operation.

B:

Set TF_LOG to a needed diagnostic level for a controlled run and protect or redact any captured output. This would be suitable for a DIFFERENT Terraform problem: An initialization failure has insufficient context, but an operator enables verbose logs and forgets the log may contain sensitive provider data. It does not directly resolve the Atlas Platform Services failure: A team expects terraform validate to confirm current cloud permissions and guaranteed sufficient quotas. The required acceptance evidence instead is: Validation passes syntactically while a deliberately revoked permission is detected during a controlled live operation.

D:

Run terraform plan and examine create/update/delete or replace actions, not just the source diff. This would be suitable for a DIFFERENT Terraform problem: A proposed firewall change contains an unintended replacement, but the team reviews only changed HCL lines. It does not directly resolve the Atlas Platform Services failure: A team expects terraform validate to confirm current cloud permissions and guaranteed sufficient quotas. The required acceptance evidence instead is: Validation passes syntactically while a deliberately revoked permission is detected during a controlled live operation.

Question 212

An acceptance reviewer at Atlas Platform Services must validate the fix for: A team expects terraform validate to confirm current cloud permissions and guaranteed sufficient quotas. What result would demonstrate that the identified problem is actually resolved?

  1. An investigator identifies the exact commit and plan that introduced the gateway size modification.
  2. The diagnostic log identifies the failing operation without being published or retaining unrestricted credentials.
  3. The plan highlights the specific replacement and allows reviewers to block it.
  4. Validation passes syntactically while a deliberately revoked permission is detected during a controlled live operation.

Explanation

Correct Answer

D:

Validation passes syntactically while a deliberately revoked permission is detected during a controlled live operation. This directly verifies the corrective action: Use validate for static configuration checks and use planning or purpose-built deployment tests for live API constraints. The measured result specifically addresses the failure at Atlas Platform Services: A team expects terraform validate to confirm current cloud permissions and guaranteed sufficient quotas.

Incorrect Answers

A:

An investigator identifies the exact commit and plan that introduced the gateway size modification. This evidence would validate a DIFFERENT correction: Version Terraform configuration and associate reviewed plan/application records with release changes. That different correction addresses: A product deployment has no record of when a gateway size was changed, making regression analysis difficult. It does not establish that the Atlas Platform Services issue has been corrected: A team expects terraform validate to confirm current cloud permissions and guaranteed sufficient quotas. The relevant measured outcome is: Validation passes syntactically while a deliberately revoked permission is detected during a controlled live operation.

B:

The diagnostic log identifies the failing operation without being published or retaining unrestricted credentials. This evidence would validate a DIFFERENT correction: Set TF_LOG to a needed diagnostic level for a controlled run and protect or redact any captured output. That different correction addresses: An initialization failure has insufficient context, but an operator enables verbose logs and forgets the log may contain sensitive provider data. It does not establish that the Atlas Platform Services issue has been corrected: A team expects terraform validate to confirm current cloud permissions and guaranteed sufficient quotas. The relevant measured outcome is: Validation passes syntactically while a deliberately revoked permission is detected during a controlled live operation.

C:

The plan highlights the specific replacement and allows reviewers to block it. This evidence would validate a DIFFERENT correction: Run terraform plan and examine create/update/delete or replace actions, not just the source diff. That different correction addresses: A proposed firewall change contains an unintended replacement, but the team reviews only changed HCL lines. It does not establish that the Atlas Platform Services issue has been corrected: A team expects terraform validate to confirm current cloud permissions and guaranteed sufficient quotas. The relevant measured outcome is: Validation passes syntactically while a deliberately revoked permission is detected during a controlled live operation.

Question 213

During repository review at Pinecrest Cloud Engineering, the platform team reports: A child module contains an undeclared variable reference but is never checked until a production deployment. What is the most appropriate corrective action for this Terraform scenario?

  1. Update the provider-defined write-only version marker according to its documented rotation mechanism.
  2. Validate the module within an initialized configuration and fix variable declarations or references.
  3. Require reviewed Terraform pull requests and an explicit plan before applying access-rule updates.
  4. Use terraform init -backend=false for an appropriate backend-free local initialization.

Explanation

Correct Answer

B:

Validate the module within an initialized configuration and fix variable declarations or references. This is targeted to the observed Terraform issue: A child module contains an undeclared variable reference but is never checked until a production deployment. At Pinecrest Cloud Engineering, the acceptance criterion is not merely a valid plan; the team should verify: The missing variable reference is rejected by validation and a corrected module passes without apply.

Incorrect Answers

A:

Update the provider-defined write-only version marker according to its documented rotation mechanism. This would be suitable for a DIFFERENT Terraform problem: A provider offers a write-only credential argument and companion version field, but a team rotates only the secret value and expects Terraform to detect the change from state. It does not directly resolve the Pinecrest Cloud Engineering failure: A child module contains an undeclared variable reference but is never checked until a production deployment. The required acceptance evidence instead is: The missing variable reference is rejected by validation and a corrected module passes without apply.

C:

Require reviewed Terraform pull requests and an explicit plan before applying access-rule updates. This would be suitable for a DIFFERENT Terraform problem: Multiple engineers change cloud access rules directly and accidentally reverse each other's settings between releases. It does not directly resolve the Pinecrest Cloud Engineering failure: A child module contains an undeclared variable reference but is never checked until a production deployment. The required acceptance evidence instead is: The missing variable reference is rejected by validation and a corrected module passes without apply.

D:

Use terraform init -backend=false for an appropriate backend-free local initialization. This would be suitable for a DIFFERENT Terraform problem: A team needs to initialize providers without contacting the configured remote backend during a local syntax-only preflight. It does not directly resolve the Pinecrest Cloud Engineering failure: A child module contains an undeclared variable reference but is never checked until a production deployment. The required acceptance evidence instead is: The missing variable reference is rejected by validation and a corrected module passes without apply.

Question 214

An acceptance reviewer at Pinecrest Cloud Engineering must validate the fix for: A child module contains an undeclared variable reference but is never checked until a production deployment. Which controlled check would validate the remediation?

  1. The plan detects the version change and the provider applies the new secret without persisting the secret itself.
  2. Provider and module dependencies initialize while the remote backend is not configured during that preflight.
  3. The missing variable reference is rejected by validation and a corrected module passes without apply.
  4. Repository history identifies the change author and the approved plan reflects only the intended access-rule modification.

Explanation

Correct Answer

C:

The missing variable reference is rejected by validation and a corrected module passes without apply. This directly verifies the corrective action: Validate the module within an initialized configuration and fix variable declarations or references. The measured result specifically addresses the failure at Pinecrest Cloud Engineering: A child module contains an undeclared variable reference but is never checked until a production deployment.

Incorrect Answers

A:

The plan detects the version change and the provider applies the new secret without persisting the secret itself. This evidence would validate a DIFFERENT correction: Update the provider-defined write-only version marker according to its documented rotation mechanism. That different correction addresses: A provider offers a write-only credential argument and companion version field, but a team rotates only the secret value and expects Terraform to detect the change from state. It does not establish that the Pinecrest Cloud Engineering issue has been corrected: A child module contains an undeclared variable reference but is never checked until a production deployment. The relevant measured outcome is: The missing variable reference is rejected by validation and a corrected module passes without apply.

B:

Provider and module dependencies initialize while the remote backend is not configured during that preflight. This evidence would validate a DIFFERENT correction: Use terraform init -backend=false for an appropriate backend-free local initialization. That different correction addresses: A team needs to initialize providers without contacting the configured remote backend during a local syntax-only preflight. It does not establish that the Pinecrest Cloud Engineering issue has been corrected: A child module contains an undeclared variable reference but is never checked until a production deployment. The relevant measured outcome is: The missing variable reference is rejected by validation and a corrected module passes without apply.

D:

Repository history identifies the change author and the approved plan reflects only the intended access-rule modification. This evidence would validate a DIFFERENT correction: Require reviewed Terraform pull requests and an explicit plan before applying access-rule updates. That different correction addresses: Multiple engineers change cloud access rules directly and accidentally reverse each other's settings between releases. It does not establish that the Pinecrest Cloud Engineering issue has been corrected: A child module contains an undeclared variable reference but is never checked until a production deployment. The relevant measured outcome is: The missing variable reference is rejected by validation and a corrected module passes without apply.

Question 215

At Parkside Technology Services, the Terraform review finds this specific problem: A child module contains an undeclared variable reference but is never checked until a production deployment. Which action would best restore the intended infrastructure-as-code workflow?

  1. Create a saved plan and apply that exact plan when the environment and approval workflow require consistency.
  2. Use the published module source syntax and a supported version constraint for the registry module.
  3. Confirm that no active writer remains before using the backend's supported lock recovery procedure.
  4. Validate the module within an initialized configuration and fix variable declarations or references.

Explanation

Correct Answer

D:

Validate the module within an initialized configuration and fix variable declarations or references. This is targeted to the observed Terraform issue: A child module contains an undeclared variable reference but is never checked until a production deployment. At Parkside Technology Services, the acceptance criterion is not merely a valid plan; the team should verify: The missing variable reference is rejected by validation and a corrected module passes without apply.

Incorrect Answers

A:

Create a saved plan and apply that exact plan when the environment and approval workflow require consistency. This would be suitable for a DIFFERENT Terraform problem: A release run compares old configurations against the cloud but never stores the changes that were actually approved. It does not directly resolve the Parkside Technology Services failure: A child module contains an undeclared variable reference but is never checked until a production deployment. The required acceptance evidence instead is: The missing variable reference is rejected by validation and a corrected module passes without apply.

B:

Use the published module source syntax and a supported version constraint for the registry module. This would be suitable for a DIFFERENT Terraform problem: A team tries to install a remote Terraform Registry module without specifying a valid registry source address. It does not directly resolve the Parkside Technology Services failure: A child module contains an undeclared variable reference but is never checked until a production deployment. The required acceptance evidence instead is: The missing variable reference is rejected by validation and a corrected module passes without apply.

C:

Confirm that no active writer remains before using the backend's supported lock recovery procedure. This would be suitable for a DIFFERENT Terraform problem: A failed run leaves an apparently stale lock, but engineers cannot tell whether another apply is still active. It does not directly resolve the Parkside Technology Services failure: A child module contains an undeclared variable reference but is never checked until a production deployment. The required acceptance evidence instead is: The missing variable reference is rejected by validation and a corrected module passes without apply.

Question 216

After corrective work at Parkside Technology Services, a reviewer requests measurable proof for: A child module contains an undeclared variable reference but is never checked until a production deployment. Which observation best confirms that the proposed correction worked?

  1. The missing variable reference is rejected by validation and a corrected module passes without apply.
  2. The applied actions correspond to the approved saved plan rather than a newly recalculated unreviewed diff.
  3. The lock is cleared only after verifying the prior process is gone and a subsequent plan obtains exclusive access.
  4. Init resolves the intended published module version and records it in the installed module manifest.

Explanation

Correct Answer

A:

The missing variable reference is rejected by validation and a corrected module passes without apply. This directly verifies the corrective action: Validate the module within an initialized configuration and fix variable declarations or references. The measured result specifically addresses the failure at Parkside Technology Services: A child module contains an undeclared variable reference but is never checked until a production deployment.

Incorrect Answers

B:

The applied actions correspond to the approved saved plan rather than a newly recalculated unreviewed diff. This evidence would validate a DIFFERENT correction: Create a saved plan and apply that exact plan when the environment and approval workflow require consistency. That different correction addresses: A release run compares old configurations against the cloud but never stores the changes that were actually approved. It does not establish that the Parkside Technology Services issue has been corrected: A child module contains an undeclared variable reference but is never checked until a production deployment. The relevant measured outcome is: The missing variable reference is rejected by validation and a corrected module passes without apply.

C:

The lock is cleared only after verifying the prior process is gone and a subsequent plan obtains exclusive access. This evidence would validate a DIFFERENT correction: Confirm that no active writer remains before using the backend's supported lock recovery procedure. That different correction addresses: A failed run leaves an apparently stale lock, but engineers cannot tell whether another apply is still active. It does not establish that the Parkside Technology Services issue has been corrected: A child module contains an undeclared variable reference but is never checked until a production deployment. The relevant measured outcome is: The missing variable reference is rejected by validation and a corrected module passes without apply.

D:

Init resolves the intended published module version and records it in the installed module manifest. This evidence would validate a DIFFERENT correction: Use the published module source syntax and a supported version constraint for the registry module. That different correction addresses: A team tries to install a remote Terraform Registry module without specifying a valid registry source address. It does not establish that the Parkside Technology Services issue has been corrected: A child module contains an undeclared variable reference but is never checked until a production deployment. The relevant measured outcome is: The missing variable reference is rejected by validation and a corrected module passes without apply.

Question 217

At Monarch Cloud Lab, the Terraform review finds this specific problem: A reviewer treats a successful terraform fmt as proof that every resource type and expression is valid. How should the Terraform engineer correct this specific failure?

  1. Treat state as potentially sensitive, keep it out of public version control, and store it in a controlled backend.
  2. Create a governed variable set and scope it to the intended project or workspaces as supported.
  3. Run terraform validate after formatting to check semantic and provider-schema consistency.
  4. Use a normal refreshed plan when current remote drift must be evaluated and review the resulting differences.

Explanation

Correct Answer

C:

Run terraform validate after formatting to check semantic and provider-schema consistency. This is targeted to the observed Terraform issue: A reviewer treats a successful terraform fmt as proof that every resource type and expression is valid. At Monarch Cloud Lab, the acceptance criterion is not merely a valid plan; the team should verify: A deliberately misspelled resource argument fails validation despite the file being correctly formatted.

Incorrect Answers

A:

Treat state as potentially sensitive, keep it out of public version control, and store it in a controlled backend. This would be suitable for a DIFFERENT Terraform problem: A teammate wants to commit terraform.tfstate to a public repository because state contains only harmless resource names. It does not directly resolve the Monarch Cloud Lab failure: A reviewer treats a successful terraform fmt as proof that every resource type and expression is valid. The required acceptance evidence instead is: A deliberately misspelled resource argument fails validation despite the file being correctly formatted.

B:

Create a governed variable set and scope it to the intended project or workspaces as supported. This would be suitable for a DIFFERENT Terraform problem: A platform team wants to share identical non-secret configuration settings across many HCP Terraform workspaces without copying them individually. It does not directly resolve the Monarch Cloud Lab failure: A reviewer treats a successful terraform fmt as proof that every resource type and expression is valid. The required acceptance evidence instead is: A deliberately misspelled resource argument fails validation despite the file being correctly formatted.

D:

Use a normal refreshed plan when current remote drift must be evaluated and review the resulting differences. This would be suitable for a DIFFERENT Terraform problem: A developer tries to prove there is no drift by using terraform plan -refresh=false in a system with known manual changes. It does not directly resolve the Monarch Cloud Lab failure: A reviewer treats a successful terraform fmt as proof that every resource type and expression is valid. The required acceptance evidence instead is: A deliberately misspelled resource argument fails validation despite the file being correctly formatted.

Question 218

After corrective work at Monarch Cloud Lab, a reviewer requests measurable proof for: A reviewer treats a successful terraform fmt as proof that every resource type and expression is valid. Which verification outcome is the strongest evidence of the required correction?

  1. The reviewed plan detects the controlled manual change instead of relying solely on stale state.
  2. A test change reaches only the authorized workspaces associated with that variable set.
  3. Repository scanning finds no state artifact and only authorized identities can read stored state.
  4. A deliberately misspelled resource argument fails validation despite the file being correctly formatted.

Explanation

Correct Answer

D:

A deliberately misspelled resource argument fails validation despite the file being correctly formatted. This directly verifies the corrective action: Run terraform validate after formatting to check semantic and provider-schema consistency. The measured result specifically addresses the failure at Monarch Cloud Lab: A reviewer treats a successful terraform fmt as proof that every resource type and expression is valid.

Incorrect Answers

A:

The reviewed plan detects the controlled manual change instead of relying solely on stale state. This evidence would validate a DIFFERENT correction: Use a normal refreshed plan when current remote drift must be evaluated and review the resulting differences. That different correction addresses: A developer tries to prove there is no drift by using terraform plan -refresh=false in a system with known manual changes. It does not establish that the Monarch Cloud Lab issue has been corrected: A reviewer treats a successful terraform fmt as proof that every resource type and expression is valid. The relevant measured outcome is: A deliberately misspelled resource argument fails validation despite the file being correctly formatted.

B:

A test change reaches only the authorized workspaces associated with that variable set. This evidence would validate a DIFFERENT correction: Create a governed variable set and scope it to the intended project or workspaces as supported. That different correction addresses: A platform team wants to share identical non-secret configuration settings across many HCP Terraform workspaces without copying them individually. It does not establish that the Monarch Cloud Lab issue has been corrected: A reviewer treats a successful terraform fmt as proof that every resource type and expression is valid. The relevant measured outcome is: A deliberately misspelled resource argument fails validation despite the file being correctly formatted.

C:

Repository scanning finds no state artifact and only authorized identities can read stored state. This evidence would validate a DIFFERENT correction: Treat state as potentially sensitive, keep it out of public version control, and store it in a controlled backend. That different correction addresses: A teammate wants to commit terraform.tfstate to a public repository because state contains only harmless resource names. It does not establish that the Monarch Cloud Lab issue has been corrected: A reviewer treats a successful terraform fmt as proof that every resource type and expression is valid. The relevant measured outcome is: A deliberately misspelled resource argument fails validation despite the file being correctly formatted.

Question 219

The infrastructure engineers at Westhaven Application Ops document the following failure during a change review: A reviewer treats a successful terraform fmt as proof that every resource type and expression is valid. What is the most appropriate corrective action for this Terraform scenario?

  1. Run terraform validate after formatting to check semantic and provider-schema consistency.
  2. Apply the previously saved reviewed plan rather than silently calculating an unrelated replacement plan.
  3. Add an input-variable validation condition enforcing a positive capacity with a clear error message.
  4. Refresh state through a normal or refresh-only plan and evaluate the resulting drift before applying any configuration change.

Explanation

Correct Answer

A:

Run terraform validate after formatting to check semantic and provider-schema consistency. This is targeted to the observed Terraform issue: A reviewer treats a successful terraform fmt as proof that every resource type and expression is valid. At Westhaven Application Ops, the acceptance criterion is not merely a valid plan; the team should verify: A deliberately misspelled resource argument fails validation despite the file being correctly formatted.

Incorrect Answers

B:

Apply the previously saved reviewed plan rather than silently calculating an unrelated replacement plan. This would be suitable for a DIFFERENT Terraform problem: A pipeline recreates a new unapproved plan between review and apply, potentially introducing changes not previously seen. It does not directly resolve the Westhaven Application Ops failure: A reviewer treats a successful terraform fmt as proof that every resource type and expression is valid. The required acceptance evidence instead is: A deliberately misspelled resource argument fails validation despite the file being correctly formatted.

C:

Add an input-variable validation condition enforcing a positive capacity with a clear error message. This would be suitable for a DIFFERENT Terraform problem: A module accepts a storage capacity variable of -5 and should fail before attempting an API call. It does not directly resolve the Westhaven Application Ops failure: A reviewer treats a successful terraform fmt as proof that every resource type and expression is valid. The required acceptance evidence instead is: A deliberately misspelled resource argument fails validation despite the file being correctly formatted.

D:

Refresh state through a normal or refresh-only plan and evaluate the resulting drift before applying any configuration change. This would be suitable for a DIFFERENT Terraform problem: A resource is manually renamed in the cloud API, but Terraform's recorded state still contains its earlier attributes. It does not directly resolve the Westhaven Application Ops failure: A reviewer treats a successful terraform fmt as proof that every resource type and expression is valid. The required acceptance evidence instead is: A deliberately misspelled resource argument fails validation despite the file being correctly formatted.

Question 220

The reliability team at Westhaven Application Ops is closing an incident described as follows: A reviewer treats a successful terraform fmt as proof that every resource type and expression is valid. Which controlled check would validate the remediation?

  1. The applied changes correspond to the same exact plan that was approved.
  2. A deliberately misspelled resource argument fails validation despite the file being correctly formatted.
  3. A negative test input is rejected and a valid capacity proceeds to planning.
  4. The plan reports the observed difference and the operator records an intentional corrective decision.

Explanation

Correct Answer

B:

A deliberately misspelled resource argument fails validation despite the file being correctly formatted. This directly verifies the corrective action: Run terraform validate after formatting to check semantic and provider-schema consistency. The measured result specifically addresses the failure at Westhaven Application Ops: A reviewer treats a successful terraform fmt as proof that every resource type and expression is valid.

Incorrect Answers

A:

The applied changes correspond to the same exact plan that was approved. This evidence would validate a DIFFERENT correction: Apply the previously saved reviewed plan rather than silently calculating an unrelated replacement plan. That different correction addresses: A pipeline recreates a new unapproved plan between review and apply, potentially introducing changes not previously seen. It does not establish that the Westhaven Application Ops issue has been corrected: A reviewer treats a successful terraform fmt as proof that every resource type and expression is valid. The relevant measured outcome is: A deliberately misspelled resource argument fails validation despite the file being correctly formatted.

C:

A negative test input is rejected and a valid capacity proceeds to planning. This evidence would validate a DIFFERENT correction: Add an input-variable validation condition enforcing a positive capacity with a clear error message. That different correction addresses: A module accepts a storage capacity variable of -5 and should fail before attempting an API call. It does not establish that the Westhaven Application Ops issue has been corrected: A reviewer treats a successful terraform fmt as proof that every resource type and expression is valid. The relevant measured outcome is: A deliberately misspelled resource argument fails validation despite the file being correctly formatted.

D:

The plan reports the observed difference and the operator records an intentional corrective decision. This evidence would validate a DIFFERENT correction: Refresh state through a normal or refresh-only plan and evaluate the resulting drift before applying any configuration change. That different correction addresses: A resource is manually renamed in the cloud API, but Terraform's recorded state still contains its earlier attributes. It does not establish that the Westhaven Application Ops issue has been corrected: A reviewer treats a successful terraform fmt as proof that every resource type and expression is valid. The relevant measured outcome is: A deliberately misspelled resource argument fails validation despite the file being correctly formatted.