Re: change default default_toast_compression to lz4?

Daniel Gustafsson <daniel@yesql.se>

From: Daniel Gustafsson <daniel@yesql.se>
To: Aleksander Alekseev <aleksander@tigerdata.com>
Cc: PostgreSQL Hackers <pgsql-hackers@postgresql.org>, Peter Eisentraut <peter@eisentraut.org>
Date: 2025-11-21T12:27:28Z
Lists: pgsql-hackers
> On 21 Nov 2025, at 12:33, Aleksander Alekseev <aleksander@tigerdata.com> wrote:

>> The default could be lz4 if
>> lz4 support is built, otherwise pglz.  This would be similar to other
>> parameters where the default is the best one depending on the build
>> configuration.

+1

> Are there good reasons why we can't simply make lz4 a required
> dependency? In the worst case we could simply copy its implementation,
> the license permits.

I think we should, as much as we can, avoid vendoring code, especially
something like lz4 which can be expected to be available nearly everywhere.

--
Daniel Gustafsson