Skip to content

Commit

Permalink
fence_vmware_soap: Use --login-timeout option (#447)
Browse files Browse the repository at this point in the history
* fence_vmware_soap: Use --login-timeout option
* Set timeout to 60s when disable-timeouts is used

Fixes issue #446.
  • Loading branch information
thanasis2028 authored Nov 3, 2021
1 parent 9c36b83 commit d6e82ce
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion agents/vmware_soap/fence_vmware_soap.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,8 @@ def soap_login(options):

try:
headers = {"Content-Type" : "text/xml;charset=UTF-8", "SOAPAction" : "vim25"}
conn = Client(url + "/vimService.wsdl", location=url, transport=RequestsTransport(verify=verify), headers=headers)
login_timeout = int(options["--login-timeout"]) or 60
conn = Client(url + "/vimService.wsdl", location=url, transport=RequestsTransport(verify=verify), headers=headers, timeout=login_timeout)

mo_ServiceInstance = Property('ServiceInstance')
mo_ServiceInstance._type = 'ServiceInstance'
Expand Down

0 comments on commit d6e82ce

Please sign in to comment.