Remove broken foreign key `fk_rails_e214655a86_p`

This foreign key was identified as corrupted and should be removed.

Steps

  • for migrate up, drop foreign key using helper remove_foreign_key_if_exists
    • make sure to use reverse_lock_order: true, see here for more info
    • make sure to wrap this method with with_lock_retries, see here for more info
  • for migrate down, recover the foreign key using helper add_concurrent_partitioned_foreign_key
    • make sure to use reverse_lock_order: true, see here for more info
  • verify that cascading deletion works for this foreign key, see #498881 (comment 2375289241) as example
Edited by Madhusudan Vaishnao