Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

could not obtain a database connection within 5.000 seconds #530

Open
almmaslim opened this issue Jun 29, 2019 · 2 comments
Open

could not obtain a database connection within 5.000 seconds #530

almmaslim opened this issue Jun 29, 2019 · 2 comments

Comments

@almmaslim
Copy link

almmaslim commented Jun 29, 2019

I'm getting this error "could not obtain a database connection within 5.000 seconds" after installing octopus. Is there a possibility that there are some connections that are not disconnected properly or something?
here is my shards.yml, ENV["DB_POOL"] = 30


octopus:
  master_shard: group1
  default_migration_group: shards_group
  environments:
    - development
    - production
  development:
    shards_group:
      group1:
        database: group1
        adapter:  postgresql
        host: localhost
        pool: <%= ENV["DB_POOL"] %>
      group2:
        database: group2
        adapter: postgresql
        host: localhost
        pool: <%= ENV["DB_POOL"] %>
@abelorian
Copy link

you could try this gem:

https://rubygems.org/gems/active_record_slave

@mufid
Copy link

mufid commented Sep 13, 2021

I am experiencing the same issue using Rails 5.2. Did you happen to find a solution?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants