# Persistent Database Connection Pooling

Solves - "I've analyzed my app's performance and it seems to be spending a lot of time just logging in to the database."

Logging in to most databases takes a noticable amount of time...

So much time, in fact, that transient apps (such as web-based applications) which start up, connect, query, disconnect, and shut down to deliver each bit of content, often take longer to log in than to run the queries. As a result, overall throughput (queries-per-second) is generally low unless many queries are run per connection.

A persistent database connection pool maintains a pool of already-logged-in database connections, and logging in to a connection pool is substantially faster than logging into the database directly.

As a result, overall throughput (queries-per-second) is maximized, and doesn't depend nearly as much on the number of queries that are run per connection.

(Current Benchmarks)

Many connection pooling systems are built into application servers or run within a web-server but can only be used by applications running within that server and usually only by applications written in a particular language. SQL Relay runs stand-alone and may be used by any application, including applications running on other machines across the network. This is especially useful if you have a variety of apps, written in different languages, running on various platforms that all need to talk to the same database.