Heikki Linnakangas <heikki.linnakan...@enterprisedb.com> writes: > To accomplish what you're trying to accomplish, you would need to label > each received WAL record with the timestamp when it was received, and > compare the reception timestamp of the record you're applying against > current timestamp.
Yeah, this is why I thought that closed-loop lag control was a research project. In practice, we don't have to track it at the individual record level. The real behavior of walsender is that we get a "gob" of WAL each activity cycle, and so tracking the WAL start location and receipt time for each gob ought to be sufficient. (In fact trying to ascribe any finer-grain receipt time than that to individual WAL records is probably bogus anyway.) It might be enough to remember the start location and time for the latest gob, depending on exactly what control algorithm you want to use. But the whole thing requires significant thought and testing, which we really haven't got time for now. regards, tom lane -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers