In our rails application we need to establish connection to database based on the client id in the URL. Currently we are using establish_connection but it looks like it creates new connection pool each time and executes some queries to get schema information about DB. Is there a way to cache connection pool ? I am also curious why did Active Record decided not to cache the connection pools based on configuration ? I am not sure if its a great idea to subclass ConnectionHandler and roll my own connection pool caching something like this any opinions ?