3

I would like to use a combination of an ELB and AutoScaling for a web application. For upgrades to the web application that don't involve changing the database, I can simply rotate all the instances in the AG with an updated image, etc.

However, if we have an upgrade with a database migration, I believe I will need to redirect all traffic to a static page while we are performing the migration.

What is the recommended way to handle these situations? Should I use an additional proxy in front of the ELB and point it to a server with the static page during the ugprade?

As you can tell I don't have a systems background, so forgive my ignorance.

akoumjian
  • 141
  • 3

1 Answers1

0

If you're able to put your website in "read only" mode that would be ideal.

Essentially you would architect the website in such a way that writes to the database are not allowed while your migration happens.

The other technique you may want to take advantage of is feature toggling. This is where you deploy the new code, but don't activate it straight away. You can then quickly "toggle" the new code on/off as it has already been deployed.

Of course this all depends on how much control you have over your code and deployments, what sort of website you have, and how much it relies on the DB.

Drew Khoury
  • 4,637
  • 8
  • 27
  • 28