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

aci_rest: Using status="created" behaves differently than status="deleted" #35050

Closed
dagwieers opened this issue Jan 18, 2018 · 8 comments
Closed
Labels
aci Cisco ACI community affects_2.4 This issue/PR affects Ansible v2.4 bug This issue/PR relates to a bug. cisco Cisco technologies module This issue/PR relates to a module. networking Network category support:certified This issue/PR relates to certified code. waiting_on_vendor This issue requires actions by the vendor. Please inquire the vendor's help for any progress.

Comments

@dagwieers
Copy link
Contributor

dagwieers commented Jan 18, 2018

ISSUE TYPE
  • Bug Report
COMPONENT NAME

aci_rest

ANSIBLE VERSION

v2.4+

SUMMARY

If you use a REST payload with aci_rest using status="created" the action is not idempotent. The first time (when the object does not exist) it works (changed=True), but a subsequent call fails as the APIC returns an HTTP failure.

However, if you do the same for removing an object using status="deleted" the action is idempotent. So a subsequent call works (and does not report a change, changed=False) as one would expect.

This seems an implementation issue in the APIC.

PS If you would add status="created,modified" or simply status="modified" your task will be idempotent and it will not lead to failures on subsequent runs.

STEPS TO REPRODUCE

This will cause a failure on a subsequent create:

<aaaUserCert dn="uni/userext/user-admin/usercert-admin" data="-----BEGIN CERTIFICATE-----\r\nMII<snip>NGg\r\n-----END CERTIFICATE\r\n" name="admin" rn="usercert-admin" status="created"/>

This will not cause a failure on a subsequent removal:

<aaaUserCert dn="uni/userext/user-admin/usercert-admin" name="admin" rn="usercert-admin" status="deleted"/>

However using status="modified" will always work.

This report wants to highlight that creation and deletion have a different behaviour.

The vendor has been notified of this inconsistency.

@dagwieers dagwieers added the aci Cisco ACI community label Jan 18, 2018
@dagwieers dagwieers modified the milestone: 2.4.0 Jan 18, 2018
@ansibot
Copy link
Contributor

ansibot commented Jan 18, 2018

Files identified in the description:

If these files are inaccurate, please update the component name section of the description or use the !component bot command.

click here for bot help

@ansibot
Copy link
Contributor

ansibot commented Jan 18, 2018

@ansibot ansibot added affects_2.4 This issue/PR affects Ansible v2.4 bug_report module This issue/PR relates to a module. networking Network category support:community This issue/PR relates to code supported by the Ansible community. labels Jan 18, 2018
@dagwieers dagwieers modified the milestone: 2.5.0 Jan 18, 2018
@dagwieers dagwieers added the waiting_on_vendor This issue requires actions by the vendor. Please inquire the vendor's help for any progress. label Jan 31, 2018
@dagwieers
Copy link
Contributor Author

dagwieers commented Feb 13, 2018

I am not able to reproduce this on version 3.0(2k) running on sandboxapicdc.cisco.com.

Either the identified problem is more complex, or this is already fixed in a newer release.

@ansibot ansibot added bug This issue/PR relates to a bug. and removed bug_report labels Mar 1, 2018
@ansibot ansibot added support:core This issue/PR relates to code supported by the Ansible Engineering Team. and removed support:community This issue/PR relates to code supported by the Ansible community. labels Sep 18, 2018
@ansibot ansibot added support:community This issue/PR relates to code supported by the Ansible community. and removed support:core This issue/PR relates to code supported by the Ansible Engineering Team. labels Oct 4, 2018
@ansibot ansibot added support:certified This issue/PR relates to certified code. and removed support:community This issue/PR relates to code supported by the Ansible community. labels Oct 12, 2018
@dagwieers dagwieers added the cisco Cisco technologies label Feb 22, 2019
@ansibot
Copy link
Contributor

ansibot commented Mar 2, 2019

@ansibot
Copy link
Contributor

ansibot commented Mar 10, 2019

@ansibot
Copy link
Contributor

ansibot commented May 29, 2019

@ansibot
Copy link
Contributor

ansibot commented Feb 16, 2020

@aciguru
Copy link
Contributor

aciguru commented Apr 14, 2020

Moved to

CiscoDevNet/ansible-aci#27

@ansible ansible locked and limited conversation to collaborators May 12, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
aci Cisco ACI community affects_2.4 This issue/PR affects Ansible v2.4 bug This issue/PR relates to a bug. cisco Cisco technologies module This issue/PR relates to a module. networking Network category support:certified This issue/PR relates to certified code. waiting_on_vendor This issue requires actions by the vendor. Please inquire the vendor's help for any progress.
Projects
None yet
Development

No branches or pull requests

3 participants