| От | Alvaro Herrera |
|---|---|
| Тема | Re: remove spurious CREATE INDEX CONCURRENTLY wait |
| Дата | |
| Msg-id | 20201117002341.GA23972@alvherre.pgsql обсуждение исходный текст |
| Ответ на | Re: remove spurious CREATE INDEX CONCURRENTLY wait (Dmitry Dolgov <9erthalion6@gmail.com>) |
| Ответы |
Re: remove spurious CREATE INDEX CONCURRENTLY wait
Re: remove spurious CREATE INDEX CONCURRENTLY wait |
| Список | pgsql-hackers |
I am really unsure about the REINDEX CONCURRENTLY part of this, for two reasons: 1. It is not as good when reindexing multiple indexes, because we can only apply the flag if *all* indexes are "safe". Any unsafe index means we step down from it for the whole thing. This is probably not worth worrying much about, but still. 2. In some of the waiting transactions, we actually do more things than what we do in CREATE INDEX CONCURRENTLY transactions --- some catalog updates, but we also do the whole index validation phase. Is that OK? It's not as clear to me that it is safe to set the flag in all those places. I moved the comments to the new function and made it inline. I also changed the way we determine how the function is safe; there's no reason to build an IndexInfo if we can simply look at rel->rd_indexprs and rel->indpred. I've been wondering if it would be sane/safe to do the WaitForFoo stuff outside of any transaction. I'll have a look again tomorrow.
В списке pgsql-hackers по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера