This commit is contained in:
spiduler
2020-10-23 16:04:00 +09:00
parent 3bca3c0ea2
commit 78c7f90947

View File

@@ -32,6 +32,9 @@ class SeleniumBrowser {
borrowed: this.pool.borrowed,
pending: this.pool.pending
}, 'Pool info')
if(this.pool.borrowed > 8) {
this.pool.clear()
}
return driver.getSession().then(s => {
logger.info('Driver session validation checked (id: %s)', s.getId())
return true
@@ -42,7 +45,7 @@ class SeleniumBrowser {
})
}
}, {
max: 2, min: 1, testOnBorrow: true, acquireTimeoutMillis: 30000
max: 10, min: 1, testOnBorrow: true, acquireTimeoutMillis: 30000
});
this.pool.on('factoryCreateError', function (err) {