Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Handle server id mismatch #33

Merged
merged 1 commit into from
Aug 27, 2024
Merged

Handle server id mismatch #33

merged 1 commit into from
Aug 27, 2024

Conversation

stuart-mclaren-hpe
Copy link
Contributor

Handle the corner case where a returned server id
may not match the id in the current terraform state.
This should never happen because id's are immutable.

If it does ever occur we will not overwrite any state and will
instead raise this error:

Error: error reading server

  with hpegl_pc_server.test,
  on terraform_plugin_test.tf line 21, in resource "hpegl_pc_server" "test":
  21:   resource "hpegl_pc_server" "test" {

'id' mismatch: 697e8cbf-df7e-570c-a3c7-912d4ce8375a !=
697e8cbf-df7e-570c-a3c7-912d4ce8375a

Handle the corner case where a returned server id
may not match the id in the current terraform state.
This should never happen because id's are immutable.

If it does ever occur we will not overwrite any state
and will instead raise this error:

```
Error: error reading server

  with hpegl_pc_server.test,
  on terraform_plugin_test.tf line 21, in resource "hpegl_pc_server" "test":
  21:   resource "hpegl_pc_server" "test" {

'id' mismatch: 697e8cbf-df7e-570c-a3c7-912d4ce8375a !=
697e8cbf-df7e-570c-a3c7-912d4ce8375a
```
@stuart-mclaren-hpe stuart-mclaren-hpe merged commit fcdfa87 into main Aug 27, 2024
4 checks passed
@stuart-mclaren-hpe stuart-mclaren-hpe deleted the write-server-id branch August 27, 2024 16:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants