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

Heroku CI: Support building rails 6 with multiple databases on multiple nodes #1209

Open
adherr opened this issue Oct 8, 2021 · 1 comment

Comments

@adherr
Copy link

adherr commented Oct 8, 2021

We have multiple postgres databases (in different clouds in production) that we want to test against with Heroku CI with multiple nodes.

  • Our primary database is set to use heroku-postgresql:in-dyno which works fine.
  • A second database is running as heroku-postgresql:standard-0, and during db:structure:load_if_sql in the buildpack, whichever node arrives first loads the structure, and all later nodes spew ERRORs about the structure already existing.
    • On occassion, two nodes attempt to apply migrations simultaneously, causing one of them to error out the build with a ActiveRecord::ConcurrentMigrationError 😞.
    • Even with transactional tests, we sometimes fail tests that count database records. This seems like a bug elsewhere, but being able to provision a second in-dyno database (another db in the same postgresql server even) would solve this problem.
@schneems
Copy link
Contributor

schneems commented Oct 6, 2023

Thanks for the issue, sorry for the delay. I don't have a fix for this or one planned, unfortunately.

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

2 participants