UpCloudLtd / upcloud-python-api

Python client for UpCloud's API
MIT License
53 stars 21 forks source link

Add hard shutdown and hard restart APIs #27

Closed akx closed 8 years ago

akx commented 8 years ago

Currently only soft shutdown and restart APIs are available.

I think this would be most fluently expressed by rephrasing

def shutdown(self):
def restart(self):

as

def shutdown(self, hard=False, timeout=30):
def restart(self, hard=False, timeout=30):
elnygren commented 8 years ago

absolutely, I'll also add timeout_action for server https://www.upcloud.com/api/8-servers/#restart-server while at it.

sane defaults and optional control is the way to go here.

elnygren commented 8 years ago

https://github.com/UpCloudLtd/upcloud-python-api/commit/f853c81167ff9218e4878901d0cac9aff5fcfa42