2

I have an application deployed on heroku. Sometimes background process raises the following error: "The task failed because of an error: could not obtain connection within 5.0 seconds. The max pool size is currently 1; consider increasing the pool size or timeout."

How can I increase pool size or the timeout? Unfortunately I can't find anything useful in Mongoid documentation and sources.

luacassus
  • 6,540
  • 2
  • 40
  • 58

1 Answers1

0

You can specify the pool size in mongoid.yml:

production:
    pool_size: 5

Details here.

friism
  • 19,068
  • 5
  • 80
  • 116