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
Refactor stop_host method to use topology #292
base: master
Are you sure you want to change the base?
Conversation
'workers': good_hosts} | ||
self.upload_topology(topology) | ||
self.cluster.stop_host(bad_host) | ||
self.cluster.stop_host(self.cluster.slaves[0]) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you've already put the bad host name in the topology, so stopping the host should really do anything. Maybe we don't need stop_host at all, just upload bad worker/coordinator topologies all around. In any case it should be one or the other.
# Change the topology to something that doesn't exist | ||
ips = self.get_ip_address_dict() | ||
down_hostname = self.get_down_hostname() | ||
self.exec_cmd_on_host( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why do we need all three of these sed commands? Doesn't the topology usually just contain the internal host name?
d5ada45
to
0131baf
Compare
@rschlussel updated version that addresses your comments. I also added a commit that fixed the |
travis failures are real. It looks like you missed a few usages of stop_host |
looks good % fixing the test failures. |
Can you also revert the timeout increase (and make sure that this fixes the issue)? |
- The requests library handles connection resets from the server better than urllib.
- Stopping a host is now done implicitly by uploading a topology that points to a host that doesn't exist. This was done because stopping a container caused nasty race conditions.
46cd187
to
0ab3512
Compare
@petroav what's the status of this? |
@rschlussel I put this on pause since we were seeing all those |
upload_topology
to mimic behavior ofstop_host
.