Since there is not documentation about how to create connection poolings with Sailsjs, I've being searching a little bit about it and I've found that sails-mysql adapter do have any pooling configuration in it but is related to tests:
{
host: process.env.WATERLINE_ADAPTER_TESTS_HOST || 'localhost',
// (...)
database: process.env.WATERLINE_ADAPTER_TESTS_DATABASE || 'sails_mysql',
pool: true,
connectionLimit: 10,
waitForConnections: true
}
So I've tried to include pool: true to my connections.js file in Sails:
someMysqlServer: {
adapter: 'sails-mysql',
host: '127.0.0.1',
user: 'root',
password: '',
pool: true,
database: 'mydatabase'
},
Server still runs and I recover data from the database but I'm not sure at all about if I have set connection throw a pooling service. Is there any way to check this feature?
Thanks.
sails-mysql-transactionsadapter. It has connection pooling, and you get transactions as well - elssar