UNPKG

702 BJavaScriptView Raw
1const { keys } = require('lodash');
2
3// The client names we'll allow in the `{name: lib}` pairing.
4const CLIENT_ALIASES = Object.freeze({
5 pg: 'postgres',
6 postgresql: 'postgres',
7 sqlite: 'sqlite3',
8});
9
10const SUPPORTED_CLIENTS = Object.freeze(
11 [
12 'mssql',
13 'mysql',
14 'mysql2',
15 'oracledb',
16 'postgres',
17 'redshift',
18 'sqlite3',
19 ].concat(keys(CLIENT_ALIASES))
20);
21
22const POOL_CONFIG_OPTIONS = Object.freeze([
23 'maxWaitingClients',
24 'testOnBorrow',
25 'fifo',
26 'priorityRange',
27 'autostart',
28 'evictionRunIntervalMillis',
29 'numTestsPerRun',
30 'softIdleTimeoutMillis',
31 'Promise',
32]);
33
34module.exports = {
35 CLIENT_ALIASES,
36 SUPPORTED_CLIENTS,
37 POOL_CONFIG_OPTIONS,
38};