Handling multiple environments without downtime

So here is the situation, we have two environments/branches in Supabase -> staging and production. We also have tho apps on the App store called App-Staging and App-Production (this one has been live on the App store for 2 months). So our worklfow is that we develop a new feature or rather change an existing feature on db-staging an deploy a new test-flight version to App-Staging where we can test it. After we are happy with it we would like to push it to db-production and App-production. The problem is that the new staging updates are not compatible with the current live version, meaning that as soon as we push db-staging to production the current live version App-production breaks. And it stays broken until the App-Production is reviewed by Apple (usually takes a day) meaning there is a day of downtime. But we need the db-production updated in order for us to test on test flight of App-production + Apple will reject the app if we try and submit a broken version. What would be the cleanest/correct solution here to minimize downtime? Any suggestions/resources? I hope I explained it well, if anyone needs clarification anywhere lmk. Thanks!
2 Replies
vick
vick6d ago
You need to write your application to understand both versions of your backend and "do the right thing". I've done this many times, but never with having to deal with app-store approvals. Right now, how are you expecting to deal with your user not having updated the app? Do you just show a "you must upgrade right now" screen? That's not very user-friendly, but it is an option.
MaGnezij
MaGnezijOP19h ago
Sorry for a late reply did not get a notification smh.. Yeah thats pretty much what we are doing, because every new feature that we are rolling out basically requires the user to be on the latest (such as in-app purchases etc.). But then again for smaller features that is a bad UX, so really we are tackling that here.. Lets say we push an upgrade to a smaller featuer for which we wouldn't want the user to force update, but still this small feature breaks the old version..

Did you find this page helpful?