Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
perf(db) improve kong startup time by reusing luasocket on kong.init
Without this patch the Postgres strategy creates 7 non-pooled luasocket connections to database on Kong.init(). This patch reduces that to 3. Without this patch the Cassandra strategy creates 9 non-pooled luasocket connections to database on Kong.init(). This patch reduces that to 1. The difference is because Postgres needs to run initialization SQL to setup the connection timezone and database schema on new connections. And for Postgres `connect_migrations` is the same as `connect` while with Cassandra it is not. It is still a tiny improvement for Postgres as well.
- Loading branch information