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

Extra client api call is necessary when updating a resource whose tf state id is not Mikrotik .id #37

Open
jdelnano opened this issue May 12, 2021 · 1 comment
Assignees

Comments

@jdelnano
Copy link
Collaborator

Many, but not all, resources for this provider are configured in such a way that their .id field is used as the terraform Id field in state. However, others use a different, unique field (e.g. name), but this causes a situation when updating a resource: The .id field will be needed by the client code, but since it isn't embedded in terraform state, an additional Find client call is needed to fetch the .id before updating. An example of each is shown below:

Resource using .id as tf Id
Resource using name as tf Id

Solution: to promote uniformity + reduce additional client API calls, adjust resources to use their .id field in terraform state.

@maksym-nazarenko
Copy link
Collaborator

this one might be closed after migrating all resources to new terraform-plugin-framework (see #134)

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

No branches or pull requests

2 participants