Concurrency and Database Connections in Ruby with ActiveRecord
15-Oct-2018 1817
When increasing concurrency by using a multi-threaded web server like Puma, or multi-process web server like Unicorn, you must be aware of the number of connections your app holds to the database and how many connections the database can accept. Each thread or process requires a different connection to the database. To accommodate this, Active Record provides a connection pool that can hold several connections at a time.
Concurrency and Database Connections in Ruby with ActiveRecord #ruby #rubydeveloper #rubyonrails #Concurrency #Database #Connections #ActiveRecord #activerecord #database https://rubyonrails.ba/link/concurrency-and-database-connections-in-ruby-with-activerecord