refactor: dns优选
parent
dfd2db5285
commit
091cbc5336
|
@ -6,14 +6,14 @@ const tunnelAgent = require('tunnel-agent')
|
||||||
const util = exports
|
const util = exports
|
||||||
const httpsAgent = new HttpsAgent({
|
const httpsAgent = new HttpsAgent({
|
||||||
keepAlive: true,
|
keepAlive: true,
|
||||||
timeout: 15000,
|
timeout: 20000,
|
||||||
keepAliveTimeout: 60000, // free socket keepalive for 30 seconds
|
keepAliveTimeout: 30000, // free socket keepalive for 30 seconds
|
||||||
rejectUnauthorized: false
|
rejectUnauthorized: false
|
||||||
})
|
})
|
||||||
const httpAgent = new Agent({
|
const httpAgent = new Agent({
|
||||||
keepAlive: true,
|
keepAlive: true,
|
||||||
timeout: 15000,
|
timeout: 20000,
|
||||||
keepAliveTimeout: 60000 // free socket keepalive for 30 seconds
|
keepAliveTimeout: 30000 // free socket keepalive for 30 seconds
|
||||||
})
|
})
|
||||||
let socketId = 0
|
let socketId = 0
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue