I was getting Sequel::PoolTimeout
errors and so I increased the :max_connections to 10 and the :pool_timeout to 10
DB = Sequel.connect('sqlite://streak.db', :max_connections => 10, :pool_timeout => 10)
Are there any negative side effects to increasing these values?
Here is a link to an excerpt of code where the Pool Timeout happened.
the list
array only ever has around 100 items in it. In each thread it parses a web page for a value and inserts into the database.
Increasing max connections could leave your server thrashing as it tries to deal with too much.
Increasing timeout means it's going to take longer to timeout in situations where the query can never finish, e.g. locks.
What you should be doing is looking at the query(s) that are timing out and make them more performant.
No idea why you increased number of connections to fix a timeout problem, thats liable to make things worse...