Possible inaccurate description of wal_compression in docs

Started by Jingtang Zhang5 months ago9 messages
#1Jingtang Zhang
mrdrivingduck@gmail.com

Hi hackers~

I find the specification of wal_compression in our docs a little bit confusing
for it 'compress full page images when FPW is on or during a base backup',
which was true before v17. Since v17, we will also use full page images for
creating index or table rewrites through bulk write, so it is inaccurate.

Should we change the doc a little bit: 'compress full page images written
to WAL, **like** when FPW is on, or during a base backup', if we may use
FPI in other places in the future?

--
Regards, Jingtang

#2Xuneng Zhou
xunengzhou@gmail.com
In reply to: Jingtang Zhang (#1)
Re: Possible inaccurate description of wal_compression in docs

Hi,

On Sun, Aug 10, 2025 at 6:53 PM Jingtang Zhang <mrdrivingduck@gmail.com> wrote:

Hi hackers~

I find the specification of wal_compression in our docs a little bit confusing
for it 'compress full page images when FPW is on or during a base backup',
which was true before v17. Since v17, we will also use full page images for
creating index or table rewrites through bulk write, so it is inaccurate.

Should we change the doc a little bit: 'compress full page images written
to WAL, **like** when FPW is on, or during a base backup', if we may use
FPI in other places in the future?

+1 for the update.

Best,
Xuneng

#3Andrey Borodin
x4mmm@yandex-team.ru
In reply to: Jingtang Zhang (#1)
Re: Possible inaccurate description of wal_compression in docs

On 10 Aug 2025, at 13:53, Jingtang Zhang <mrdrivingduck@gmail.com> wrote:

Hi hackers~

I find the specification of wal_compression in our docs a little bit confusing
for it 'compress full page images when FPW is on or during a base backup',
which was true before v17. Since v17, we will also use full page images for
creating index or table rewrites through bulk write, so it is inaccurate.

Should we change the doc a little bit: 'compress full page images written
to WAL, **like** when FPW is on, or during a base backup', if we may use
FPI in other places in the future?

FPWs are used here and there in a lot of places, like "FPI for hint". And indexes are build using FPI for many years, it did not start with 17...
This list is not exhaustive in any case, so I agree that formulation should not be very strict.

Best regards, Andrey Borodin.

#4Jingtang Zhang
mrdrivingduck@gmail.com
In reply to: Andrey Borodin (#3)
Re: Possible inaccurate description of wal_compression in docs

Hi~

FPWs are used here and there in a lot of places, like "FPI for hint". And indexes are build using FPI for many years, it did not start with 17...

Yeah, my fault. Creating index prior to v17 was also using log_newpages.


Regards, Jingtang

#5Michael Paquier
michael@paquier.xyz
In reply to: Andrey Borodin (#3)
Re: Possible inaccurate description of wal_compression in docs

On Mon, Aug 11, 2025 at 06:59:55PM +0300, Andrey Borodin wrote:

FPWs are used here and there in a lot of places, like "FPI for
hint". And indexes are build using FPI for many years, it did not
start with 17...
This list is not exhaustive in any case, so I agree that formulation
should not be very strict.

Perhaps, yes, the formulation used in this paragraph could be a bit
more evasive. What we do not want is to keep a wording that would
require more maintenance each time the internals of the backend are
changed, so adding an extra "like" may be OK.

Do any of you have a specific wording in mind?
--
Michael

#6Xuneng Zhou
xunengzhou@gmail.com
In reply to: Michael Paquier (#5)
Re: Possible inaccurate description of wal_compression in docs

Hi,

On Tue, Aug 12, 2025 at 12:41 PM Michael Paquier <michael@paquier.xyz>
wrote:

On Mon, Aug 11, 2025 at 06:59:55PM +0300, Andrey Borodin wrote:

FPWs are used here and there in a lot of places, like "FPI for
hint". And indexes are build using FPI for many years, it did not
start with 17...
This list is not exhaustive in any case, so I agree that formulation
should not be very strict.

Perhaps, yes, the formulation used in this paragraph could be a bit
more evasive. What we do not want is to keep a wording that would
require more maintenance each time the internals of the backend are
changed, so adding an extra "like" may be OK.

Do any of you have a specific wording in mind?

"Like" LGMT.

Best,
Xuneng

#7Jingtang Zhang
mrdrivingduck@gmail.com
In reply to: Michael Paquier (#5)
Re: Possible inaccurate description of wal_compression in docs

Do any of you have a specific wording in mind?

'Like when FPW is on …' would be okay, or '(e.g., when FPW is on …)'
would be formal?

--
Regards, Jingtang

#8Xuneng Zhou
xunengzhou@gmail.com
In reply to: Jingtang Zhang (#7)
Re: Possible inaccurate description of wal_compression in docs

Hi,

On Wed, Aug 13, 2025 at 11:22 PM Jingtang Zhang <mrdrivingduck@gmail.com> wrote:

Do any of you have a specific wording in mind?

'Like when FPW is on …' would be okay, or '(e.g., when FPW is on …)'
would be formal?

+1 for e.g.

Best,
Xuneng

#9Michael Paquier
michael@paquier.xyz
In reply to: Xuneng Zhou (#8)
Re: Possible inaccurate description of wal_compression in docs

On Wed, Aug 20, 2025 at 09:01:12AM +0800, Xuneng Zhou wrote:

+1 for e.g.

e.g. feels more elegant, so I have reused your suggestion, and applied
the result down to v13.
--
Michael