Skip to content

500 Internal Server Error when deleting a MongoDB Flex #1363

@mcpomm

Description

@mcpomm

Description

500 Internal Server Error when deleting a MongoDB Flex instance using terraform destroy.

Actual behavior

When deleting a MongoDB Flex instance via terraform destroy, the following error always occurs:
Error: Error deleting instance

│ Instance deletion waiting: 500 Internal Server Error, status code 500,
│ Body: {“message”:“internal server error”,“code”:500,‘type’:“Read”}

Although the instance is deleted at Stackit, the error causes the Terraform process to abort and the state is not updated.
Consequently, a terraform apply fails with the same error message because the state is corrupted.
Currently, we have to manually delete the remote state and reapply it.

Expected behavior

terraform destroy should delete the instance and update the state accordingly.

Environment

  • OS: MacOS Tahoe 26.4
  • Terraform version: v1.14.2
  • Version of the STACKIT Terraform provider: v0.90.0

Additional information

Image

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions