Skip to content

Commit

Permalink
Merge pull request #591 from seegno/allow-config-override
Browse files Browse the repository at this point in the history
Add support for overriding generic pool defaults
  • Loading branch information
brianc committed May 22, 2014
2 parents f8df873 + 7612bbc commit e81245f
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions lib/pool.js
Expand Up @@ -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) {
Expand Down

0 comments on commit e81245f

Please sign in to comment.