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

Created Objects removed when running in Async plays (DCNE-98) #153

Open
FraserHenshaw opened this issue Jan 12, 2021 · 2 comments
Open

Created Objects removed when running in Async plays (DCNE-98) #153

FraserHenshaw opened this issue Jan 12, 2021 · 2 comments
Labels
API bug Something isn't working jira-sync Sync this issue to Jira

Comments

@FraserHenshaw
Copy link

SUMMARY
When rerunning this modues in Async mode objects show as being created/changed but are then removed from a template an example of this would be a play to create 10 EPG's, in the play these all show as completing successfully but then if we go to apply contracts to these EPG's the Contract module reports back that some of the EPG's dont exist.

I have seen this happening with EPG/Contract and filter creation.

ISSUE TYPE
Bug Report

COMPONENT NAME
mso_schema_template_anp_epg and others

ANSIBLE VERSION
ansible 2.10.4

STEPS TO REPRODUCE
To test, built the EPG with the config below. doesnt appear to happen 100% of the time and the objects that are removed each time appear to be different.

  hosts: localhost
  name: Deploy EPGs
  tasks:
  - async: 60
    cisco.mso.mso_schema_template_anp_epg:
      <<: *mso-login
      anp: '{{ item.anp | default(omit) }}'
      bd: '{{ item.bd | default(omit) }}'
      epg: '{{ item.epg | default(omit) }}'
      schema: '{{ item.schema | default(omit) }}'
      template: '{{ item.template | default(omit) }}'
    loop:
    - anp: TEST_AP
      bd:
        name: TestBD
        schema: TestSchema
        template: TestTemplate
      epg: EPG_1
      schema: TestSchema
      template: TestTemplate
    - anp: TEST_AP
      bd:
        name: TestBD
        schema: TestSchema
        template: TestTemplate
      epg: EPG_2
      schema: TestSchema
      template: TestTemplate
    - anp: TEST_AP
      bd:
        name: TestBD
        schema: TestSchema
        template: TestTemplate
      epg: EPG_3
      schema: TestSchema
      template: TestTemplate
    name: Building Configuration for EPGs
    poll: 0
    register: epg_tasks
  - async_status:
      jid: '{{ item.ansible_job_id }}'
    loop: '{{ epg_tasks.results }}'
    name: Deploying Configuration for EPGs
    register: epg_finished
    until: epg_finished.finished

- gather_facts: false
  hosts: localhost
  name: Deploy EPG to Contract Maps
  tasks:
  - async: 60
    cisco.mso.mso_schema_template_anp_epg_contract:
      <<: *mso-login
      anp: '{{ item.anp | default(omit) }}'
      contract: '{{ item.contract | default(omit) }}'
      epg: '{{ item.epg | default(omit) }}'
      schema: '{{ item.schema | default(omit) }}'
      template: '{{ item.template | default(omit) }}'
    loop:
    - anp: TEST_AP
      contract:
        name: TEST_CONTRACT_1
        type: provider
      epg: EPG_1
      schema: TestSchema
      template: TestTemplate
    - anp: TEST_AP
      contract:
        name: TEST_CONTRACT_1
        type: provider
      epg: EPG_2
      schema: TestSchema
      template: TestTemplate
    - anp: TEST_AP
      contract:
        name: TEST_CONTRACT_1
        type: provider
      epg: EPG_3
      schema: TestSchema
      template: TestTemplate
    - anp: TEST_AP
      contract:
        name: TEST_CONTRACT_2
        type: consumer
      epg: EPG_3
      schema: TestSchema
      template: TestTemplate
    name: Building Configuration for EPG to Contract Maps
    poll: 0
    register: epg_to_contract_tasks
  - async_status:
      jid: '{{ item.ansible_job_id }}'
    loop: '{{ epg_to_contract_tasks.results }}'
    name: Deploying Configuration for EPG to Contract Maps
    register: epg_to_contract_finished
    until: epg_to_contract_finished.finished
@lhercot
Copy link
Member

lhercot commented Jan 21, 2021

Hi Fraser, this seems to be an API related issue. We are investigating the issue with the API engineering owner.
Will update when we have a solution.

@lhercot lhercot added API bug Something isn't working labels Jan 21, 2021
@FraserHenshaw
Copy link
Author

thanks for the update,

if confirmed do you know if htis will get a CSC Bug code we can use to track at all?

@anvitha-jain anvitha-jain removed their assignment Apr 11, 2022
@samiib samiib added the jira-sync Sync this issue to Jira label Aug 14, 2024
@github-actions github-actions bot changed the title Created Objects removed when running in Async plays Created Objects removed when running in Async plays (DCNE-98) Aug 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
API bug Something isn't working jira-sync Sync this issue to Jira
Projects
None yet
Development

No branches or pull requests

4 participants