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

Sleep some more time in ansible targeted refresh #14899

Merged

Conversation

durandom
Copy link
Member

the sleep here is also needed because tower needs some time
to actually propagate it's updates

if we would return immediately it could be that the we get
the old playbooks

So we always sleep 1 second after the update has finished

the whole sleep business is a workaround anyway until we get
proper polling via #14405

adresses https://bugzilla.redhat.com/show_bug.cgi?id=1442170

@miq-bot add_label bug, providers/ansible_tower

the sleep here is also needed because tower needs some time
to actually propagate it's updates
if we would return immediately it _could_ be that the we get
the old playbooks

the whole sleep business is a workaround anyway until we get
proper polling via ManageIQ#14405
@durandom
Copy link
Member Author

@miq-bot assign @agrare

@miq-bot
Copy link
Member

miq-bot commented Apr 26, 2017

Checked commit durandom@85090c9 with ruby 2.2.6, rubocop 0.47.1, and haml-lint 0.20.0
1 file checked, 0 offenses detected
Everything looks fine. 🍰

# if we would return immediately it _could_ be that the we get the old playbooks
# the whole sleep business is a workaround anyway until we get proper polling via the PR mentioned above
sleep REFRESH_ON_TOWER_SLEEP
break if project_update.finished.present?
Copy link
Member

Choose a reason for hiding this comment

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

Is the problem that even though the API reports something in project_update.finished the update isn't actually finished?

Copy link
Member Author

Choose a reason for hiding this comment

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

my guess is, the update has finished (update is a job in tower), but it takes some ms to propagate those changes to the playbook tables...

Copy link
Member

@agrare agrare left a comment

Choose a reason for hiding this comment

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

👍

@agrare agrare merged commit 91c9461 into ManageIQ:master Apr 26, 2017
@agrare agrare added this to the Sprint 60 Ending May 8, 2017 milestone May 3, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants