Re: [HACKERS] make async slave to wait for lsn to be replayed
От
Ivan Kartyshov
Тема
Re: [HACKERS] make async slave to wait for lsn to be replayed
Дата
Msg-id
de402dc80e39c358dedf174c13bb5226@postgrespro.ru
Ответ на
Список
Дерево обсуждения
make async slave to wait for lsn to be replayed Ivan Kartyshov <i.kartyshov@postgrespro.ru>
Re: make async slave to wait for lsn to be replayed Thomas Munro <thomas.munro@enterprisedb.com>
Re: [HACKERS] make async slave to wait for lsn to be replayed Ivan Kartyshov <i.kartyshov@postgrespro.ru>
Re: [HACKERS] make async slave to wait for lsn to be replayed Thom Brown <thom@linux.com>
Re: [HACKERS] make async slave to wait for lsn to be replayed Thomas Munro <thomas.munro@enterprisedb.com>
Re: [HACKERS] make async slave to wait for lsn to be replayed David Steele <david@pgmasters.net>
Re: [HACKERS] make async slave to wait for lsn to be replayed Ivan Kartyshov <i.kartyshov@postgrespro.ru>
Re: [HACKERS] make async slave to wait for lsn to be replayed Masahiko Sawada <sawada.mshk@gmail.com>
Re: [HACKERS] make async slave to wait for lsn to be replayed Ivan Kartyshov <i.kartyshov@postgrespro.ru>
Re: [HACKERS] make async slave to wait for lsn to be replayed Thomas Munro <thomas.munro@enterprisedb.com>
Re: [HACKERS] make async slave to wait for lsn to be replayed i.kartyshov@postgrespro.ru
Re: [HACKERS] make async slave to wait for lsn to be replayed David Steele <david@pgmasters.net>
Re: make async slave to wait for lsn to be replayed David Steele <david@pgmasters.net>
Re: [HACKERS] make async slave to wait for lsn to be replayed Robert Haas <robertmhaas@gmail.com>
Re: [HACKERS] make async slave to wait for lsn to be replayed Craig Ringer <craig@2ndquadrant.com>
Re: [HACKERS] make async slave to wait for lsn to be replayed i.kartyshov@postgrespro.ru
Re: [HACKERS] make async slave to wait for lsn to be replayed Ants Aasma <ants.aasma@eesti.ee>
Re: [HACKERS] make async slave to wait for lsn to be replayed Robert Haas <robertmhaas@gmail.com>
Re: [HACKERS] make async slave to wait for lsn to be replayed Peter Eisentraut <peter.eisentraut@2ndquadrant.com>
Re: [HACKERS] make async slave to wait for lsn to be replayed Thomas Munro <thomas.munro@enterprisedb.com>
Re: [HACKERS] make async slave to wait for lsn to be replayed Alexander Korotkov <a.korotkov@postgrespro.ru>
Re: [HACKERS] make async slave to wait for lsn to be replayed Ivan Kartyshov <i.kartyshov@postgrespro.ru>
Re: [HACKERS] make async slave to wait for lsn to be replayed Ivan Kartyshov <i.kartyshov@postgrespro.ru>
Re: [HACKERS] make async slave to wait for lsn to be replayed Alexander Korotkov <a.korotkov@postgrespro.ru>
Re: [HACKERS] make async slave to wait for lsn to be replayed Ivan Kartyshov <i.kartyshov@postgrespro.ru>
Re: [HACKERS] make async slave to wait for lsn to be replayed Ants Aasma <ants.aasma@eesti.ee>
Re: [HACKERS] make async slave to wait for lsn to be replayed Robert Haas <robertmhaas@gmail.com>
Re: [HACKERS] make async slave to wait for lsn to be replayed Ivan Kartyshov <i.kartyshov@postgrespro.ru>
Re: [HACKERS] make async slave to wait for lsn to be replayed Stephen Frost <sfrost@snowman.net>
Re: [HACKERS] make async slave to wait for lsn to be replayed Simon Riggs <simon@2ndquadrant.com>
Re: [HACKERS] make async slave to wait for lsn to be replayed Stephen Frost <sfrost@snowman.net>
Re: [HACKERS] make async slave to wait for lsn to be replayed Ants Aasma <ants.aasma@eesti.ee>
Re: [HACKERS] make async slave to wait for lsn to be replayed Michael Paquier <michael.paquier@gmail.com>
Re: [HACKERS] make async slave to wait for lsn to be replayed Simon Riggs <simon@2ndquadrant.com>
Re: [HACKERS] make async slave to wait for lsn to be replayed Robert Haas <robertmhaas@gmail.com>
Re: [HACKERS] make async slave to wait for lsn to be replayed Simon Riggs <simon@2ndquadrant.com>
Re: [HACKERS] make async slave to wait for lsn to be replayed Andres Freund <andres@anarazel.de>
Re: [HACKERS] make async slave to wait for lsn to be replayed Ivan Kartyshov <i.kartyshov@postgrespro.ru>
Re: [HACKERS] make async slave to wait for lsn to be replayed Michael Paquier <michael@paquier.xyz>
Re: Re: [HACKERS] make async slave to wait for lsn to be replayed David Steele <david@pgmasters.net>
Re: Re: [HACKERS] make async slave to wait for lsn to be replayed Fujii Masao <masao.fujii@gmail.com>
Re: [HACKERS] make async slave to wait for lsn to be replayed David Steele <david@pgmasters.net>
Re: [HACKERS] make async slave to wait for lsn to be replayed Michael Paquier <michael@paquier.xyz>
Re: [HACKERS] make async slave to wait for lsn to be replayed Dmitry Ivanov <d.ivanov@postgrespro.ru>
Re: [HACKERS] make async slave to wait for lsn to be replayed Simon Riggs <simon@2ndquadrant.com>
Re: make async slave to wait for lsn to be replayed Thomas Munro <thomas.munro@enterprisedb.com>
Re: make async slave to wait for lsn to be replayed Craig Ringer <craig@2ndquadrant.com>
Re: make async slave to wait for lsn to be replayed Ivan Kartyshov <i.kartyshov@postgrespro.ru>
Ants Aasma писал 2017-10-26 17:29: > On Mon, Oct 23, 2017 at 12:29 PM, Ivan Kartyshov > wrote: >> Ants Aasma писал 2017-09-26 13:00: >>> >>> Exposing this interface as WAITLSN will encode that visibility order >>> matches LSN order. This removes any chance of fixing for example >>> visibility order of async/vs/sync transactions. Just renaming it so >>> the token is an opaque commit visibility token that just happens to >>> be >>> a LSN would still allow for progress in transaction management. For >>> example, making PostgreSQL distributed will likely want timestamp >>> and/or vector clock based visibility rules. >> >> >> I'm sorry I did not understand exactly what you meant. >> Please explain this in more detail. > > Currently transactions on the master become visible when xid is > removed from proc array. This depends on the order of acquiring > ProcArrayLock, which can happen in a different order from inserting > the commit record to wal. Whereas on the standby the transactions will > become visible in the same order that commit records appear in wal. > The difference can be quite large when transactions are using > different values for synchronous_commit. Fixing this is not easy, but > we may want to do it someday. IIRC CSN threads contained more > discussion on this topic. If we do fix it, it seems likely that what > we need to wait on is not LSN, but some other kind of value. If the UI > were something like "WAITVISIBILITY token", then we can later change > the token to something other than LSN. > > Regards, > Ants Aasma It sounds reasonable. I can offer the following version. WAIT LSN lsn_number; WAIT LSN lsn_number TIMEOUT delay; WAIT LSN lsn_number INFINITE; WAIT LSN lsn_number NOWAIT; WAIT [token] wait_value [option]; token - [LSN, TIME | TIMESTAMP | CSN | XID] option - [TIMEOUT | INFINITE | NOWAIT] Ready to listen to your suggestions. -- Ivan Kartyshov Postgres Professional: http://www.postgrespro.com The Russian Postgres Company -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers
В списке pgsql-hackers по дате отправления
От: Robert Haas
Дата:
От: ilmari@ilmari.org (Dagfinn Ilmari Mannsåker)
Дата: