Fix netconf connection command timeout issue (#58322)

*  ncclient uses same timeout value at the time
   of connection initialisation and waiting response
*  Ansible has connect_timeout to control the waiting
   time during initial connection and `command_timeout`
   to control the wait time for resposne. Hence set the
   ncclient timeout seperately to Ansible command_timeout
   after the connection object is created sucessfully.
pull/58407/head
Ganesh Nalawade 5 years ago committed by Paul Belanger
parent 4591a300ae
commit db0fe4b188

@ -321,6 +321,8 @@ class Connection(NetworkConnectionBase):
timeout=self.get_option('persistent_connect_timeout'),
ssh_config=self._ssh_config
)
self._manager._timeout = self.get_option('persistent_command_timeout')
except SSHUnknownHostError as exc:
raise AnsibleConnectionFailure(to_native(exc))
except ImportError as exc:

Loading…
Cancel
Save