Re: Error "initial slot snapshot too large" in create replication slot
От | Dilip Kumar |
---|---|
Тема | Re: Error "initial slot snapshot too large" in create replication slot |
Дата | |
Msg-id | CAFiTN-sVLdkdBzJFr2+b9iPvQ_MfWYQ2mhDAXP=cpbmyw-evNg@mail.gmail.com обсуждение исходный текст |
Ответ на | Re: Error "initial slot snapshot too large" in create replication slot (Dilip Kumar <dilipbalaut@gmail.com>) |
Ответы |
Re: Error "initial slot snapshot too large" in create replication slot
|
Список | pgsql-hackers |
On Tue, Oct 12, 2021 at 11:30 AM Dilip Kumar <dilipbalaut@gmail.com> wrote: > > On Tue, Oct 12, 2021 at 10:35 AM Kyotaro Horiguchi > <horikyota.ntt@gmail.com> wrote: > > > > At Tue, 12 Oct 2021 13:59:59 +0900 (JST), Kyotaro Horiguchi <horikyota.ntt@gmail.com> wrote in > > > So I came up with the attached version. > > > > Sorry, it was losing a piece of change. > > Yeah, at a high level this is on the idea I have in mind, I will do a > detailed review in a day or two. Thanks for working on this. While doing the detailed review, I think there are a couple of problems with the patch, the main problem of storing all the xid in the snap->subxip is that once we mark the snapshot overflown then the XidInMVCCSnapshot, will not search the subxip array, instead it will fetch the topXid and search in the snap->xip array. Another issue is that the total xids could be GetMaxSnapshotSubxidCount() +GetMaxSnapshotXidCount(). I think what we should be doing is that if the xid is know subxid then add in the snap->subxip array otherwise in snap->xip array. So snap->xip array size will be GetMaxSnapshotXidCount() whereas the snap->subxip array size will be GetMaxSnapshotSubxidCount(). And if the array size is full then we can stop adding the subxids to the array. What is your thought on this? -- Regards, Dilip Kumar EnterpriseDB: http://www.enterprisedb.com
В списке pgsql-hackers по дате отправления: