def delete(self, name):
ns = self.get(name)
- resp = self._http.delete_cmd('{}/{}'.format(self._apiBase,ns['_id']))
- # print 'RESP: {}'.format(resp)
- if resp is None:
+ http_code, resp = self._http.delete_cmd('{}/{}'.format(self._apiBase,ns['_id']))
+ #print 'RESP: {}'.format(resp)
+ if http_code == 202:
+ print 'Deletion in progress'
+ elif http_code == 204:
print 'Deleted'
else:
raise ClientException("failed to delete ns {}: {}".format(name, resp))