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

(GH-185) Remove unnecessary checks in check_ready_vm #188

Merged
merged 1 commit into from
Mar 2, 2017

Conversation

glennsarti
Copy link
Contributor

@glennsarti glennsarti commented Mar 1, 2017

Previously in check_ready_vm, if the VM is powered off, the VM is moved in
redis however the function doesn't return there, and instead then checks if the
hostname is the same, and then if TCP socket 22 is open. This is unnecessary as
we already know the VM is turned off so of course the hostname is wrong and TCP
22 is unavailable. The same applies for the VM hostname.

This commit instead returns after it is found a VM is no longer ready. This
commit also amends the spec tests for the correct behaviour.

Note - This PR is blocked on PR #183 being merged

@glennsarti glennsarti changed the title (GH-185) Remove unnecessary checks in check_ready_vm {WIP}(GH-185) Remove unnecessary checks in check_ready_vm Mar 1, 2017
@glennsarti glennsarti force-pushed the ticket/master/gh-185 branch 2 times, most recently from 98ba00f to e98e131 Compare March 2, 2017 04:26
@glennsarti glennsarti changed the title {WIP}(GH-185) Remove unnecessary checks in check_ready_vm (GH-185) Remove unnecessary checks in check_ready_vm Mar 2, 2017
Previously in check_ready_vm, if the VM is powered off, the VM is moved in
redis however the function doesn't return there, and instead then checks if the
hostname is the same, and then if TCP socket 22 is open. This is unnecessary as
we already know the VM is turned off so of course the hostname is wrong and TCP
22 is unavailable. The same applies for the VM hostname.

This commit instead returns after it is found a VM is no longer ready.  This
commit also amends the spec tests for the correct behaviour.
@glennsarti glennsarti force-pushed the ticket/master/gh-185 branch from e98e131 to f433056 Compare March 2, 2017 04:28
@underscorgan underscorgan merged commit cc79bce into puppetlabs:master Mar 2, 2017
@glennsarti glennsarti deleted the ticket/master/gh-185 branch March 2, 2017 23:08
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.

3 participants