Advanced search indexed columns modified by db migrations will be out of sync

Background

Related discussion: !181649 (comment 2354391817)

Advanced search indexed columns rely upon ActiveRecord callbacks to update the indexed data. If those columns are modified using database migrations, the data will be out of sync.

Proposal

We could create a rubocop or some other automation (bot message) to alert developers that an indexed column is being used in a db migration.

For regular migrations, an Advanced search migration could be included.

For post deployment migration, the finalization migration could include the Advanced search migration.