Skip to content

routier-collection


routier-collection / plugins/mysql/src / MysqlDbPluginConfig

Interface: MysqlDbPluginConfig

Defined in: plugins/mysql/src/MysqlDbPlugin.ts:10

Properties

host?

optional host: string

Defined in: plugins/mysql/src/MysqlDbPlugin.ts:11


port?

optional port: number

Defined in: plugins/mysql/src/MysqlDbPlugin.ts:12


database?

optional database: string

Defined in: plugins/mysql/src/MysqlDbPlugin.ts:14

Required unless connectionString is given, which carries the database itself.


user?

optional user: string

Defined in: plugins/mysql/src/MysqlDbPlugin.ts:15


password?

optional password: string

Defined in: plugins/mysql/src/MysqlDbPlugin.ts:16


connectionString?

optional connectionString: string

Defined in: plugins/mysql/src/MysqlDbPlugin.ts:25

A mysql://user:password@host:port/database URI, passed straight to mysql2.

Mutually exclusive with the discrete fields above — supplying both throws rather than silently picking one. There is no correct precedence to guess: a connection string that disagrees with an explicit host means the caller believes something untrue about where their data is going.


pool?

optional pool: object

Defined in: plugins/mysql/src/MysqlDbPlugin.ts:26

max?

optional max: number

Maximum pooled connections (mysql2's connectionLimit). Default 10.

There is no min: mysql2 opens connections on demand and has no minimum-size concept. The field used to exist here and was silently discarded, which is worse than not offering it.

Released under the MIT License.