-
Notifications
You must be signed in to change notification settings - Fork 4.4k
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
Automatic database upgrades upon services start-up #7162
Conversation
Ahhh. This looks like it's causing a CI failure by attempting a database upgrade even before the database has been initialised. @zachliu Are you ok to investigate and get it working? 😄 |
@justinclift we probably need a "wait" in redash/.github/workflows/ci.yml Lines 162 to 163 in c42b151
do you prefer a blunt |
Hmmm, I wonder why we're skipping the database seed on one line, then running it manually on the next line? At some point I probably knew the answer to that. 😉 That being said, of your two options we should probably take the smarter 😄 approach and wait for the previous step to actually be complete. |
actually, redash has been using a simple redash/.github/workflows/ci.yml Lines 50 to 52 in c42b151
i figure i'll just keep it simple and consistent with the existing code 😁 dumb question: i'll need another PR to update the CI right? otherwise it won't take effect |
Is this change too dangerous? |
In theory (!) it shouldn't be, at least for not-big-version-jumps (of Redash version). People trying to run the development code directly against a Redash database from prior-to-version-10 might have issues though (am guessing). But that would be a very unexpected situation for someone to try unless intentionally getting creative for some reason. 😉 |
No worries.
Nah. In theory the CI runs from the state of the repo as it is presented by the PR itself. ie it'll make a At least, that's my present understanding of things. Does that help? 😄 |
OK! |
interesting, then it's very odd that the
|
Well, that's weird then. 😕 Maybe do some test PR's in a different fork or something along those lines? |
did some tests in my own fork and found the problem(s):
opened two new PRs: |
Cool. 😄 Heh Heh Heh, I really thought it was whatever the state of the PR branch was that controlled it. But something every day I guess. 😄
Makes sense. Not a race condition then, just an order-of-operation thing. Good stuff @zachliu, I'll take a look at those when I'm at the co-working space later on today. 😁 |
It's going to have to be tomorrow instead. Today I went through the investigation of broken embeds instead (finding a good enough workaround), and now I'm mentally brain drained. I've finished the embeds investigation now though, so this will be the first thing to look at tomorrow (unless something urgent pops up overnight). 😄 |
What type of PR is this?
Description
Automatically upgrade the database upon services start-up. So that we don't need to do it manually using cli tools on the server.
I started the discussion #7005 on automated db migration mechanisms.
Further discussing: #7161 (comment)
How is this tested?
Related Tickets & Documents
Mobile & Desktop Screenshots/Recordings (if there are UI changes)