A Node.js MySQL driver that exclusively supports connection pools and generator-based (co) asynchronous flow with transaction support. Version 1.0.2 is stable with no recent updates. It provides a simple API around pool initialization, queries, transactions, and rollbacks. Unlike mysql2 or knex, it uses yield/co patterns and requires global pool initialization before any query. It is minimal and opinionated, making it suitable for legacy generator-based Node.js projects.
npm install k9-mysqlNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Initializes a MySQL connection pool and runs a simple SELECT query using the generator-style API wrapped in async/await.
Use initmysqlpool before any query operation.
Wrap calls in a co generator or promisify them.
Use require() instead of import.
Initialize pool at application startup.
Use const { initmysqlpool } = require('k9-mysql');Run npm install mysql
Ensure initmysqlpool is called first with valid options.