Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

We have an asp.net/MVC2 web app hosted on Amazon windows IIS7 that I would like to deploy updates to with as little downtime as possible.

Building on IIS ARR 3-site setup as described here http://serverfault.com/questions/124274/zero-downtime-uploads-rollback-in-iis I would like to come up with a way to deploy my database updates (MySQL on Amazon RDS) in a way that minimizes or eliminates downtime.

Is anyone doing anything like this? The app must be deployed against a db of the right schema version and we have a system that manages those changes during a rollout.

I can imagine using ARR to gracefully drain the live site and bring up the newly-provisioned site while simultaneously running the db migrations and having the new app hold processing of web requests until the db changes were done but that seems very hard to coordinate timing on and even harder to test, not to mention the issue of client timeouts if the process takes longer than the browser wants to wait.

Thanks!

share|improve this question
add comment

1 Answer

Nobody has a great answer for this. You have to make backwards-compatible schema changes, however hard that may be.

Typically this means that your app can't just depend on one schema version, but needs to be able to support multiple schemas during the transition. (Your transactions should update both schemas, etc.)

Note that even NoSQL schema-less datastores don't solve this problem, but rather require you to solve it, in much the same way: if you have a key with N values, and you need to add a new value, your app needs to deal with the possibility that the key might not be updated yet.

Good luck!

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.