Page MenuHomePhabricator

Change `image` view to properly expose the new `img_description_id` field
Closed, ResolvedPublic

Description

There will be two rounds of changes needed. Since we stopped writing image_comment_temp instead of doing a WRITE_BOTH mode, we went ahead and did the migration despite "round 1" not having been done. We can now move immediately to "round 2":

  • On the comment table, replace the EXISTS clause referring to image_comment_temp with one referring to image
  • On the image view:
    • The img_description_id field is just img_description_id, nothing fancy.
    • Remove the join against image_comment_temp
  • On the image_compat view:
    • The img_description_id field is just img_description_id, nothing fancy.
    • For the img_description field, the test becomes just img_description_id = 0
    • Remove the join against image_comment_temp
    • The comment join condition becomes on comment_id = img_description_id
  • Remove the line in index-conf.sql about the added index on image_comment_temp. Add one for image.

Event Timeline

This is unblocked now, and should be done soon.

Change 471040 had a related patch set uploaded (by Anomie; owner: Anomie):
[operations/puppet@production] wiki replicas: Remove reference to image_comment_temp

https://gerrit.wikimedia.org/r/471040

Change 471040 merged by Bstorm:
[operations/puppet@production] wiki replicas: Remove reference to image_comment_temp

https://gerrit.wikimedia.org/r/471040

So would the replicated stuff on the replica servers be ready for me to run the scripts? Just double-checking before I go on with depooling and regenerating the views.

It should be ready, yes. The image_comment_temp table is already emptied in production on all wikis, with all the rows having had the data migrated into img_description_id. Maintenance is in progress to backfill img_description_id from img_description.

Change 471295 had a related patch set uploaded (by Bstorm; owner: Bstorm):
[operations/puppet@production] wiki replicas: depool lasbdb1010 for view changes

https://gerrit.wikimedia.org/r/471295

Change 471295 merged by Banyek:
[operations/puppet@production] wiki replicas: depool lasbdb1010 for view changes

https://gerrit.wikimedia.org/r/471295

Change 472492 had a related patch set uploaded (by Bstorm; owner: Bstorm):
[operations/puppet@production] wiki replicas: depool labsdb1009 for updates

https://gerrit.wikimedia.org/r/472492

Change 472492 merged by Banyek:
[operations/puppet@production] wiki replicas: depool labsdb1009 for updates

https://gerrit.wikimedia.org/r/472492

Change 472530 had a related patch set uploaded (by GTirloni; owner: GTirloni):
[operations/puppet@production] Revert "wiki replicas: depool labsdb1009 for updates"

https://gerrit.wikimedia.org/r/472530

Mentioned in SAL (#wikimedia-operations) [2018-11-09T09:08:01Z] <banyek@deploy1001> Synchronized wmf-config/db-eqiad.php: T189158: depool db1106 (duration: 00m 55s)

Mentioned in SAL (#wikimedia-operations) [2018-11-09T12:40:49Z] <banyek@deploy1001> Synchronized wmf-config/db-eqiad.php: T189158: repool db1106 (duration: 00m 53s)

Change 472530 merged by Banyek:
[operations/puppet@production] Revert "wiki replicas: depool labsdb1009 for updates"

https://gerrit.wikimedia.org/r/472530

Change 472670 had a related patch set uploaded (by GTirloni; owner: GTirloni):
[operations/puppet@production] wiki replicas: depool lasbdb1011 for changes

https://gerrit.wikimedia.org/r/472670

Change 472670 merged by Banyek:
[operations/puppet@production] wiki replicas: depool lasbdb1011 for changes

https://gerrit.wikimedia.org/r/472670

Change 472696 had a related patch set uploaded (by GTirloni; owner: GTirloni):
[operations/puppet@production] Revert "wiki replicas: depool lasbdb1011 for changes"

https://gerrit.wikimedia.org/r/472696

Mentioned in SAL (#wikimedia-operations) [2018-11-09T19:39:51Z] <banyek|away> repooling labsdb1011 (T189158)

Change 472696 merged by Banyek:
[operations/puppet@production] Revert "wiki replicas: depool lasbdb1011 for changes"

https://gerrit.wikimedia.org/r/472696

The patch is deployed throughout. Should that be it for this task @Anomie ?

Yes, if it's deployed to all the cloud replicas this task can be closed. Thanks!