Merge pull request #591 from seegno/allow-config-override
Add support for overriding generic pool defaults
This commit is contained in:
commit
e81245fce4
@ -17,10 +17,10 @@ var pools = {
|
||||
}
|
||||
pool = genericPool.Pool({
|
||||
name: name,
|
||||
max: defaults.poolSize,
|
||||
idleTimeoutMillis: defaults.poolIdleTimeout,
|
||||
reapIntervalMillis: defaults.reapIntervalMillis,
|
||||
log: defaults.poolLog,
|
||||
max: clientConfig.poolSize || defaults.poolSize,
|
||||
idleTimeoutMillis: clientConfig.poolIdleTimeout || defaults.poolIdleTimeout,
|
||||
reapIntervalMillis: clientConfig.reapIntervalMillis || defaults.reapIntervalMillis,
|
||||
log: clientConfig.poolLog || defaults.poolLog,
|
||||
create: function(cb) {
|
||||
var client = new pools.Client(clientConfig);
|
||||
client.connect(function(err) {
|
||||
|
Loading…
Reference in New Issue
Block a user