Page MenuHomePhabricator

Drop gbw_address and gbw_target_central_id from the global_block_whitelist table on WMF wikis
Closed, ResolvedPublic

Description

  1. ALTERs to run:
  2. Where to run those changes: all.dblist
  3. When to run those changes: When DBA has time - cleanup work that isn't blocking anything
  4. If the schema change is backwards compatible: Columns being dropped are no longer used anywhere
  5. If the schema change has been tested already on some of the test/beta wikis: Applied to the beta cluster
  6. If the data should be made available on the labs replicas and/or dumps: No changes to the current visibility of the global_block_whitelist table are needed

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald Transcript
Dreamy_Jazz renamed this task from Drop gbw_address and gbw_target_central_id from the global_block_whitelist table to Drop gbw_address and gbw_target_central_id from the global_block_whitelist table on WMF wikis.Nov 1 2024, 11:17 AM
Ladsgroup moved this task from Triage to In progress on the DBA board.
Ladsgroup moved this task from In progress to Done on the DBA board.
Tacsipacsi subscribed.

Wiki Replicas weren’t updated, making the view there unusable. :( See https://quarry.wmcloud.org/query/91385: it says

View 'enwiki_p.global_block_whitelist' references invalid table(s) or column(s) or function(s) or definer/invoker of view lack rights to use them

and if I remove the DESCRIBE command, I get the following query (reformatted for readability):

CREATE ALGORITHM=UNDEFINED DEFINER=`viewmaster`@`%` SQL SECURITY DEFINER VIEW `global_block_whitelist` AS
	SELECT
		`enwiki`.`global_block_whitelist`.`gbw_id` AS `gbw_id`,
		`enwiki`.`global_block_whitelist`.`gbw_address` AS `gbw_address`, -- this was dropped
		`enwiki`.`global_block_whitelist`.`gbw_by` AS `gbw_by`,
		`enwiki`.`global_block_whitelist`.`gbw_by_text` AS `gbw_by_text`,
		`enwiki`.`global_block_whitelist`.`gbw_reason` AS `gbw_reason`,
		`enwiki`.`global_block_whitelist`.`gbw_expiry` AS `gbw_expiry`,
		`enwiki`.`global_block_whitelist`.`gbw_target_central_id` AS `gbw_target_central_id` -- and so was this
	FROM
		`enwiki`.`global_block_whitelist`;

Please also update the views to drop the no longer existing columns.