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

Changed username and urls to computed to fix the idempotency #231

Merged
merged 2 commits into from
Jul 26, 2023

Conversation

anvitha-jain
Copy link
Collaborator

solves #224

@anvitha-jain anvitha-jain linked an issue Jul 20, 2023 that may be closed by this pull request
@anvitha-jain anvitha-jain self-assigned this Jul 20, 2023
Copy link
Collaborator

@shrsr shrsr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just the comment above--

mso/resource_mso_site.go Outdated Show resolved Hide resolved
shrsr
shrsr previously approved these changes Jul 20, 2023
Copy link
Collaborator

@shrsr shrsr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Copy link
Collaborator Author

@anvitha-jain anvitha-jain left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Had too revert by removing computed: true for location argument since it affects idempotency.

akinross
akinross previously approved these changes Jul 24, 2023
Copy link
Collaborator

@akinross akinross left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Copy link
Collaborator

@shrsr shrsr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Adding Computed : True to location is affecting the idempotent behaviour because your Terraform configuration file does not have a value for location. When you try to re-apply after the first apply your state which has now has a value for location is compared with your configuration which finds the location empty.

Let's discuss with Lionel if we want the omit this.

shrsr
shrsr previously approved these changes Jul 25, 2023
Copy link
Collaborator

@shrsr shrsr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

akinross
akinross previously approved these changes Jul 26, 2023
Copy link
Collaborator

@akinross akinross left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

…anaged. Also, fix errorForObjectNotFound function in utils to error out when new "error" payload is found.
Copy link
Member

@lhercot lhercot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@lhercot lhercot merged commit 3f9fdb8 into CiscoDevNet:master Jul 26, 2023
@anvitha-jain anvitha-jain deleted the site_vals branch August 28, 2023 06:45
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.

Cannot add site with mso_site
4 participants