Re: Skipping logical replication transactions on subscriber side
От | Amit Kapila |
---|---|
Тема | Re: Skipping logical replication transactions on subscriber side |
Дата | |
Msg-id | CAA4eK1Jx_bLc+0nLGcHQaN9g1OGf=GvzOGY=wEq06V66ytCpfA@mail.gmail.com обсуждение исходный текст |
Ответ на | Re: Skipping logical replication transactions on subscriber side (Masahiko Sawada <sawada.mshk@gmail.com>) |
Ответы |
Re: Skipping logical replication transactions on subscriber side
|
Список | pgsql-hackers |
On Fri, Oct 1, 2021 at 6:30 AM Masahiko Sawada <sawada.mshk@gmail.com> wrote: > > On Fri, Oct 1, 2021 at 5:05 AM Peter Eisentraut > <peter.eisentraut@enterprisedb.com> wrote: > > > > Also, what happens when you forget to reset the xid after it has passed? > > Will it get skipped again after wraparound? > > Yes. > Aren't we resetting the skip_xid once we skip that transaction in stop_skipping_changes()? If so, it shouldn't be possible to skip it again after the wraparound. Am I missing something? Now, if the user has wrongly set some XID which we can't skip as that is already in past or something like that then I think it is the user's problem and that's why it can be done only by super users. I think we have even thought of protecting that via cross-checking with the information in view but as the view data is lossy, we can't rely on that. I think users can even set some valid XID that never has any error and we will still skip it which is what can be done today also by pg_replication_origin_advance(). I am not sure if we can do much about such scenarios except to carefully document them. -- With Regards, Amit Kapila.
В списке pgsql-hackers по дате отправления: