pg.ddx.io  pgsql-general@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Laurenz Albe <laurenz.albe@cybertec.at>
To: Dominique Devienne <ddevienne@gmail.com>
To: Tushar Takate <tushar11.takate@gmail.com>
To: daniel@yesql.se
Cc: pgsql-general@lists.postgresql.org
Subject: Re: PostgreSQL in-transit compression for a client connection
Date: Thu, 27 Apr 2023 11:55:15 +0200
Message-ID: <5be87a471484600306d4e4922a6587fc9a6bf3b7.camel@cybertec.at> (raw)
In-Reply-To: <CAFCRh--2o+r3ZJqmxDSUEXseJKoYqDskdhTt=RxeWs2sBspzUQ@mail.gmail.com>
References: <CAE4W+SKfXRnCBYpkJMMy7dzfx81wq53nQLK_Ltcgn9qcpRYX4A@mail.gmail.com>
	<eb2ffb52aab533f382f9fcc80e9620e5044b3d88.camel@cybertec.at>
	<CAFCRh--2o+r3ZJqmxDSUEXseJKoYqDskdhTt=RxeWs2sBspzUQ@mail.gmail.com>

On Thu, 2023-04-27 at 11:44 +0200, Dominique Devienne wrote:
> as someone who must store ZLIB (from ZIP files)
> and sometimes LZ4 compressed `bytea` values, I often find it's a shame that I have
> to decompress them, send them over the wire uncompressed, to have the PostgreSQL
> backend recompress them when TOAST'ed. That's a waste of CPU and IO bandwidth...

That's not what you were looking for, but why not store the compressed data
in the database (after SET STORAGE EXTERNAL on the column) and uncompress
them after you have received them on the client side?

Yours,
Laurenz Albe





view thread (7+ messages)  latest in thread

Message-ID: <5be87a471484600306d4e4922a6587fc9a6bf3b7.camel@cybertec.at>
Permalink:  ../5be87a471484600306d4e4922a6587fc9a6bf3b7.camel@cybertec.at/
Also on:    postgresql.org/message-id/5be87a471484600306d4e4922a6587fc9a6bf3b7.camel@cybertec.at

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-general@postgresql.org
  Cc: laurenz.albe@cybertec.at, ddevienne@gmail.com, tushar11.takate@gmail.com, daniel@yesql.se
  Subject: Re: PostgreSQL in-transit compression for a client connection
  In-Reply-To: <5be87a471484600306d4e4922a6587fc9a6bf3b7.camel@cybertec.at>
  References: <CAE4W+SKfXRnCBYpkJMMy7dzfx81wq53nQLK_Ltcgn9qcpRYX4A@mail.gmail.com> <eb2ffb52aab533f382f9fcc80e9620e5044b3d88.camel@cybertec.at> <CAFCRh--2o+r3ZJqmxDSUEXseJKoYqDskdhTt=RxeWs2sBspzUQ@mail.gmail.com> <5be87a471484600306d4e4922a6587fc9a6bf3b7.camel@cybertec.at>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox