Page MenuHomePhabricator

Define minimum criteria for using the "official" schema change process
Closed, DeclinedPublic

Description

According to https://wikitech.wikimedia.org/wiki/Schema_changes/Coordination_proposal all changes to existing database tables require DBA approval, which should be planned as taking up to 2 weeks. While that is reasonable for many MediaWiki tables, which often contain millions of rows or get hundreds of reads per second, development is disproportionately concentrated at small tables, since most actively developed features are new and still in beta feature status, and not enabled by many users, which means they only get a fraction of the normal Wikimedia traffic levels. At the same time, these are the tables where velocity of change matters the most; anything that cannot be done in a single sprint will hold the whole team back. There are also non-beta examples of tables where a schema change has a negligible impact: functionality that's limited to advanced rights holders and thus rarely used, extensions which live on a single special page, or are only deployed on a small sister project.

Using the standard schema change permission workflow for such tables is bad for everyone: it keeps the developers from moving fast, it delays the feature providing value to the users, it wastes the DBAs' time on trivial changes that do not require their expertise. Eventually, it might result in developers "routing around" the bottleneck, such as storing JSON blobs in a table because that way a "schema change" can be done with a simple UPDATE command. (The example is not fictional.)

There should be some kind if minimum criteria (along the lines of "at least X rows or Y writes per minute or Z reads per minute") under which schema changes can be done on a self-service basis.

Event Timeline

Tgr raised the priority of this task from to Needs Triage.
Tgr updated the task description. (Show Details)
Tgr added a project: DBA.
Tgr subscribed.
jcrespo claimed this task.

The policy has not changed, only expanded. The old text said: " If you are changing anything in how the database is setup (columns, tables, column types, etc), you need to use this process. All schema changes must be reviewed by DB Ops and/or Platform Engineering."

Talk to release engineering if you want to change the process, this has been done with their blessing.

T121335 You change took 4 days to take effect, I now, as a new thing, guarantee to do it in under 2 weeks if the change is easy (when obviously, the effective time will be less). Before that, there was no guarantee.

If anyone wants to become a DBA and be able to apply schema changes, I am open to it.