[HACKERS] May cause infinite loop when initializing rel-cache containspartitioned table

Поиск
Список
Период
Сортировка
От 甄明洋
Тема [HACKERS] May cause infinite loop when initializing rel-cache containspartitioned table
Дата
Msg-id 57bd1e1.1886.15bd7b79cee.Coremail.18612389267@yeah.net
обсуждение исходный текст
Ответы Re: [HACKERS] May cause infinite loop when initializing rel-cachecontains partitioned table  (Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>)
Список pgsql-hackers
The function of  initializing rel-cache is RelationCacheInitializePhase3 and in src/backend/utils/cache/relcache.c file.
When initializing the partition description information, we forget to check if partition key or descriptor is NULL. 
Therefore, after the loop restarts, the partition information will be initialized again, resulting in an infinite loop.
Code:
/*
* Reload partition key and descriptor for a partitioned table.
*/
if (relation->rd_rel->relkind == RELKIND_PARTITIONED_TABLE)
{
RelationBuildPartitionKey(relation);
Assert(relation->rd_partkey != NULL);

RelationBuildPartitionDesc(relation);
Assert(relation->rd_partdesc != NULL);

restart = true;
}



 

В списке pgsql-hackers по дате отправления:

Предыдущее
От: Magnus Hagander
Дата:
Сообщение: Re: [HACKERS] Error message on missing SCRAM authentication witholder clients
Следующее
От: Pavan Deolasee
Дата:
Сообщение: Re: [HACKERS] logical replication and PANIC during shutdowncheckpoint in publisher