From ec8e8c67083404440d40067e5a40351521295397 Mon Sep 17 00:00:00 2001 From: Jannis R Date: Wed, 3 Mar 2021 13:54:07 +0100 Subject: connect()/request(): add connectTimeout with 60s default closes #7 --- readme.md | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'readme.md') diff --git a/readme.md b/readme.md index 791efe2..3b3ff89 100644 --- a/readme.md +++ b/readme.md @@ -135,6 +135,8 @@ request(pathOrUrl, opt = {}, cb) useClientCerts: false, letUserConfirmClientCertUsage: null, clientCertStore: defaultClientCertStore, + // time to wait for socket connection & TLS handshake + connectTimeout: 60 * 1000, // 60s // additional options to be passed into `tls.connect` tlsOpt: {}, } @@ -155,6 +157,8 @@ connect(opt = {}, cb) port: 1965, // client certificate cert: null, key: null, passphrase: null, + // time to wait for socket connection & TLS handshake + connectTimeout: 60 * 1000, // 60s // additional options to be passed into `tls.connect` tlsOpt: {}, } -- cgit v1.3