public inbox for [email protected]
help / color / mirror / Atom feedFrom: Justin Pryzby <[email protected]>
Subject: [PATCH 7/7] TMP: pg_dump: use lz4 by default, for CI only
Date: Wed, 4 Jan 2023 21:21:53 -0600
---
src/bin/pg_dump/pg_dump.c | 7 +++++--
src/bin/pg_dump/t/002_pg_dump.pl | 8 ++++----
2 files changed, 9 insertions(+), 6 deletions(-)
diff --git a/src/bin/pg_dump/pg_dump.c b/src/bin/pg_dump/pg_dump.c
index 224d2c900ce..cf5083c432f 100644
--- a/src/bin/pg_dump/pg_dump.c
+++ b/src/bin/pg_dump/pg_dump.c
@@ -733,8 +733,11 @@ main(int argc, char **argv)
#ifdef HAVE_LIBZ
parse_compress_specification(PG_COMPRESSION_GZIP, NULL,
&compression_spec);
-#else
- /* Nothing to do in the default case */
+#endif
+
+#ifdef USE_LZ4
+ parse_compress_specification(PG_COMPRESSION_LZ4, NULL,
+ &compression_spec);
#endif
}
diff --git a/src/bin/pg_dump/t/002_pg_dump.pl b/src/bin/pg_dump/t/002_pg_dump.pl
index 263995a2b7a..3485ebca57d 100644
--- a/src/bin/pg_dump/t/002_pg_dump.pl
+++ b/src/bin/pg_dump/t/002_pg_dump.pl
@@ -313,9 +313,9 @@ my %pgdump_runs = (
command =>
[ 'pg_restore', '-l', "$tempdir/defaults_custom_format.dump", ],
expected => $supports_gzip ?
- qr/Compression: gzip/ :
+ qr/Compression: lz4/ :
qr/Compression: none/,
- name => 'data content is gzip-compressed by default if available',
+ name => 'data content is lz4-compressed by default if available',
},
},
@@ -338,7 +338,7 @@ my %pgdump_runs = (
command =>
[ 'pg_restore', '-l', "$tempdir/defaults_dir_format", ],
expected => $supports_gzip ?
- qr/Compression: gzip/ :
+ qr/Compression: lz4/ :
qr/Compression: none/,
name => 'data content is gzip-compressed by default',
},
@@ -346,7 +346,7 @@ my %pgdump_runs = (
"$tempdir/defaults_dir_format/toc.dat",
"$tempdir/defaults_dir_format/blobs.toc",
$supports_gzip ?
- "$tempdir/defaults_dir_format/*.dat.gz" :
+ "$tempdir/defaults_dir_format/*.dat.lz4" :
"$tempdir/defaults_dir_format/*.dat",
],
},
--
2.25.1
--e7jIye1Ygp5H0AIi--
view thread (14+ messages) latest in thread
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 using the --to and --cc options:
reply via email
To: [email protected]
Cc: [email protected]
Subject: Re: [PATCH 7/7] TMP: pg_dump: use lz4 by default, for CI only
In-Reply-To: <no-message-id-1857775@localhost>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox