sdfdf
This commit is contained in:
@@ -34,7 +34,7 @@ class SeleniumBrowser {
|
||||
})
|
||||
}
|
||||
}, {
|
||||
max: 20, min: 1, testOnBorrow: true
|
||||
max: 20, min: 1, testOnBorrow: true, acquireTimeoutMillis: 5000
|
||||
});
|
||||
|
||||
this.pool.on('factoryCreateError', function (err) {
|
||||
@@ -45,12 +45,12 @@ class SeleniumBrowser {
|
||||
logger.error({ message: err.message }, 'pool error')
|
||||
})
|
||||
|
||||
this.pool.use(driver => {
|
||||
return driver.getSession().then(s => driver).catch(err => {
|
||||
this.pool.destroy(driver)
|
||||
throw new Error('Driver session expired pool should create new instance')
|
||||
})
|
||||
})
|
||||
// this.pool.use(driver => {
|
||||
// return driver.getSession().then(s => driver).catch(err => {
|
||||
// this.pool.destroy(driver)
|
||||
// throw new Error('Driver session expired pool should create new instance')
|
||||
// })
|
||||
// })
|
||||
}
|
||||
|
||||
getDriver() {
|
||||
|
||||
Reference in New Issue
Block a user