N
Neon6mo ago
correct-apricot

Why one of the arguments of GetPage is LSN?

Hello Neon Team, I'm trying to figure out how Neon works, and I can't figure out one detail. One of the arguments to the GetPage function is an LSN, which is needed to determine the page version. However, as I understand it, pageserver is part of the storage manager (in the sense that in read-only compute, on which GetPage is called, it is precisely part of the storage manager). In postgresql, LSN (which in my understanding is similar in meaning to xid) is used in access methods to determine the version of a relation using MVCC, that is, it is a higher-level mechanism, and the storage manager simply searches for a specific page and does not know anything about MVCC. Why does GetPage accept an LSN as input, and not just give out a page with the required number upon request, if it is supposedly part of the storage manager? What should I read to better understand the motivation for such a decision? I read some articles from your blog, in particular https://neon.tech/blog/persistent-structures-in-neons-wal-indexing, but I couldn't understand from them the reason why this API is designed like this
1 Reply
fair-rose
fair-rose6mo ago
please try the #neon-oss channel below.

Did you find this page helpful?