Database schema management for lazybones: from chaos to heaven
Performing database schema changes on a live system is challenging because it often involves high level of locks leading to downtime. It becomes harder and harder when the number of databases to manage raise continuously. At OVHcloud, a major cloud computing provider in Europe, we used to manage such changes approximately. With our startup mindset, we used to yell "Who can ALTER my database?" and hope for someone sitting next to you to answer. Database engineers were used to copy paste bunch of SQL statements on production databases directly. What happens if a bad character is inserted? What if there is no transaction in the script? What if you run the migration on the wrong database? It works, sometimes. Lots of tasks are boring. This one was on top of our list. In this talk, you will discover our feedback on how we have reduced efforts, time and human errors by automating databases schema migrations using git, code reviews, CI/CD, migration tools and Ansible at the OVHcloud scale.