Re: Introduce pg_receivewal gzip compression tests - Mailing list pgsql-hackers

From gkokolatos@pm.me
Subject Re: Introduce pg_receivewal gzip compression tests
Date
Msg-id nr63G0R6veCrLY30QMwxYA2aCawclWJopZiKEDN8HtKwIoIqZ79fVmSE2GxTyPD1Mk9FzRdfLCrc-BSGO6vTlDT_E2-aqtWeEiNn-qsDDzk=@pm.me
Whole thread Raw
In response to Re: Introduce pg_receivewal gzip compression tests  (Michael Paquier <michael@paquier.xyz>)
Responses Re: Introduce pg_receivewal gzip compression tests
List pgsql-hackers

‐‐‐‐‐‐‐ Original Message ‐‐‐‐‐‐‐

On Monday, July 12th, 2021 at 13:04, Michael Paquier <michael@paquier.xyz> wrote:

> On Mon, Jul 12, 2021 at 09:42:32AM +0000, gkokolatos@pm.me wrote:
>
> > This to my understanding means that gzip is expected to exist.
> >
> > If this is correct, then simply checking for the headers should
> >
> > suffice, since that is the only dependency for the files to be
> >
> > created.
>
> You cannot expect this to work on Windows when it comes to MSVC for
>
> example, as gzip may not be in the environment PATH so the test would
>
> fail hard. Let's just rely on $ENV{GZIP} instead, and skip the test
>
> if it is not defined.

I am admittedly not so well versed on Windows systems. Thank you for
informing me.

Please find attached v3 of the patch where $ENV{GZIP_PROGRAM} is used
instead. To the best of my knowledge one should avoid using $ENV{GZIP}
because that would translate to the obsolete, yet used environment
variable GZIP which holds a set of default options for gzip. In essence
it would be equivalent to executing:
   GZIP=gzip gzip --test <files>
which can result to errors similar to:
   gzip: gzip: non-option in GZIP environment variable

Cheers,
//Georgios

>
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
>
> Michael
Attachment

pgsql-hackers by date:

Previous
From: gkokolatos@pm.me
Date:
Subject: Re: Introduce pg_receivewal gzip compression tests
Next
From: Andy Fan
Date:
Subject: Re: Zedstore - compressed in-core columnar storage