-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathsettings.js
58 lines (42 loc) · 1.45 KB
/
settings.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
// Default unit: milli-second
module.exports = {
// Whether to return the response stream
"piping" : false,
// When set true, htp will not stage response body in piping mode.
"pipingOnly": false,
// Default protocol.
"protocol": "http:",
// Whether to reject unsecure response.
"rejectUnauthorized": true,
// Whether HTTP/HTTPS agent will keep alive for more requests.
"keepAlive": true,
// HTTP/HTTPS proxy.
"proxy": null,
// ---------------------------
// Time-related settings.
// Unit: micro-seconds (except those delared explicitly)
// Time used to finish the whole request.
// ATTENTION: Time used to hostname resolving test is included.
// dns.lookup() -- "end" event
"request_timeout" : 120000,
// Time used to resolve hostname.
// dns.lookup() -- address returned
"dns_timeout" : 5000,
// DNS TTL.
// Unit: seconds
"dns_ttl" : 60,
// Time used to plug into socket.
// http(s).request() -- "socket" event
"plugin_timeout" : 100,
// Time used to shake-hands with target server.
// "socket" event -- "connect" event
"connect_timeout" : 30000,
// Time used to recieve the first response from target server.
// "connect" event -- first "data" event (first data chunk arrives)
"response_timeout" : 60000,
// Time between two data chunks.
"chunk_timeout" : 5000,
// Time used to receive all data.
// "connect" event -- "end" event (all data chunks arrive)
"data_timeout" : 90000,
};