A lightweight wrapper around the mysql npm package that enhances connection pool performance and adds configuration options inspired by Java DBCP (e.g., queueTimeout, testOnBorrow, minIdle, maxReuseCount). Version 1.0.3 is the latest stable release. It provides up to 80% throughput improvement for high-concurrency workloads by optimizing pool acquisition. Primarily maintained for legacy Node.js 0.6+ projects. The package monkey-patches the existing mysql module and extends both pool and PoolCluster functionality. Not compatible with the newer mysql2 driver or modern ESM imports.
npm install mysql-pool-boosterNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Create a boosted mysql connection pool with extended options and use the convenient pool.query shorthand.
Always boost the mysql object immediately after require and before any other usage. Avoid boosting multiple times.
Consider migrating to `mysql2` which has built-in promise support and better pool performance.
Set `testOnBorrow: false` if your connections are reliable, or increase `testOnBorrowInterval`.
Upgrade Node.js to at least 0.10, or avoid using `timeBetweenEvictionRunsMillis`.
Use `const MysqlPoolBooster = require('mysql-pool-booster')` instead of a named import.Always call `MysqlPoolBooster(mysql)` with the mysql module as argument.
Run `npm install mysql` before using mysql-pool-booster.