RE: ReplicationSlotRelease() crashes when the instance is in the single user mode
От | Hayato Kuroda (Fujitsu) |
---|---|
Тема | RE: ReplicationSlotRelease() crashes when the instance is in the single user mode |
Дата | |
Msg-id | OSCPR01MB14966D87D8EB0D9CD32C6A43DF530A@OSCPR01MB14966.jpnprd01.prod.outlook.com обсуждение исходный текст |
Ответ на | Re: ReplicationSlotRelease() crashes when the instance is in the single user mode (Michael Paquier <michael@paquier.xyz>) |
Ответы |
RE: ReplicationSlotRelease() crashes when the instance is in the single user mode
Re: ReplicationSlotRelease() crashes when the instance is in the single user mode |
Список | pgsql-hackers |
Dear Michael, Paul, Mutaamba, > FWIW, I had my doubts at the beginning on the thread about the > use-case, but after re-reading the whole thing I am going to side with > Robert's opinion that if a fix to authorize some of the operations is > simple, then let's just authorize the case(s) and have the fix. OK, thanks for the clarification. Let's focus on 0001 now. > Echoing with Paul, what I find as critically lacking from the proposed > patches are regression tests to check and validate the behaviors you > are looking for in the patches. Please add some in the shape of perl > commands that use direct --single commands of postgres. We have cases > that do so currently in the tree: sepgsql and shm. I don't see a > reason why we could not do that as well here with run_log(). It is > also possible to pass a -c exit_on_error=true to force failures. > > Not having a test for the single-user case of a slot drop is of course > something that we are lacking now. As we are playing with this area > of the code, let's add something for this case as well. I added a first version of the test. It could work on my env (Linux). Since I cannot come up the appropriate place, I introduced new test file in recovery test. creating/dropping/advancing a slot, and doing a logical decoding is tested. Since standby mode is not supported by the single-user instance, I did not test the slot synchronization. I have not known that. 0002 was updated accordingly just in case. In the patch some functions were expected to fail. Also, a check for pg_sync_replication_slots() was removed because we cannot call the function in the first place. IIUC, 0001 can be backpatched for all supported branches. I will create for them after patch would be a good shape. Best regards, Hayato Kuroda FUJITSU LIMITED
Вложения
В списке pgsql-hackers по дате отправления: