Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hEb6G-0000GL-F9 for pgsql-hackers@arkaria.postgresql.org; Thu, 11 Apr 2019 14:54:48 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1hEb6E-0002s3-7b for pgsql-hackers@arkaria.postgresql.org; Thu, 11 Apr 2019 14:54:46 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hEb6D-0002rw-Rk for pgsql-hackers@lists.postgresql.org; Thu, 11 Apr 2019 14:54:45 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hEb6B-0003tx-6m for pgsql-hackers@postgresql.org; Thu, 11 Apr 2019 14:54:44 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.4/8.14.4) with ESMTP id x3BEsKee011258; Thu, 11 Apr 2019 10:54:20 -0400 From: Tom Lane To: Ashwin Agrawal cc: Mark Kirkwood , PostgreSQL mailing lists Subject: Re: Zedstore - compressed in-core columnar storage In-reply-to: <6A2B85A8-1ABD-4F85-981E-C94172D662FD@pivotal.io> References: <6A2B85A8-1ABD-4F85-981E-C94172D662FD@pivotal.io> Comments: In-reply-to Ashwin Agrawal message dated "Wed, 10 Apr 2019 22:03:26 -0700" MIME-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-ID: <11256.1554994460.1@sss.pgh.pa.us> Content-Transfer-Encoding: quoted-printable Date: Thu, 11 Apr 2019 10:54:20 -0400 Message-ID: <11257.1554994460@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk Ashwin Agrawal writes: > Thank you for trying it out. Yes, noticed for certain patterns pg_lzcomp= ress() actually requires much larger output buffers. Like for one 86 len s= ource it required 2296 len output buffer. Current zedstore code doesn=E2=80= =99t handle this case and errors out. LZ4 for same patterns works fine, wo= uld highly recommend using LZ4 only, as anyways speed is very fast as well= with it. You realize of course that *every* compression method has some inputs that it makes bigger. If your code assumes that compression always produces a smaller string, that's a bug in your code, not the compression algorithm. regards, tom lane