mirror of https://github.com/zulip/zulip.git
88937655fd
This needs to be done in three South migrations to not block users from sending messages for a long time. Adding the column requires a write lock on the zephyr_message table and populating the new column takes a long time. Thus, we can't do them both in the same transaction (which South forces on migrations). Additionally, creating the index takes a lot of computation and needs to lock the table when not done CONCURRENTLY, which can't be done inside of a transaction. To do this manual change, you need to run: python manage.py migrate zephyr 0007 ssh postgres.humbughq.com 'echo "CREATE INDEX CONCURRENTLY zephyr_message_search_tsvector ON zephyr_message USING gin(search_tsvector);" | psql' python manage.py migrate zephyr 0008 on staging. No action is required on prod since the database is shared. Note that this migration must be done completely before we switch to using the tsvector cache column. (imported from commit b6a27013a60c1fd196eabb095d2d11d20bba5aac) |
||
---|---|---|
.. | ||
0001_initial.py | ||
0002_auto__add_field_preregistrationuser_referred_by__add_field_preregistra.py | ||
0003_auto__add_field_stream_invite_only.py | ||
0004_add_postgres_zephyr_message_full_text_idx.py | ||
0005_auto__add_field_subscription_in_home_view.py | ||
0006_add_zephyr_message_search_tsvector.py | ||
0007_populate_zephyr_message_search_tsvector.py | ||
0008_index_zephyr_message_search_tsvector.py | ||
__init__.py |