From: Laurenz Albe <laurenz.albe@cybertec.at>
To: Donato Marrazzo <donato.marrazzo@gmail.com>
To: pgsql-admin@lists.postgresql.org
Subject: Re: How to get more than 2^32 BLOBs
Date: Wed, 08 Apr 2020 12:06:43 +0200
Message-ID: <98e38782369def5f1fb865533ab22d828b442d78.camel@cybertec.at> (raw)
In-Reply-To: <CAC1K4Ghi6fa0ck4rrB4MSaOLas9MY4mnF-jNF4iwiy75UVj4iQ@mail.gmail.com>
References: <CAC1K4Ghi6fa0ck4rrB4MSaOLas9MY4mnF-jNF4iwiy75UVj4iQ@mail.gmail.com>
On Wed, 2020-04-08 at 11:15 +0200, Donato Marrazzo wrote:
> according this page [1], large object are limited to the OID range of 2^32 (since it's a 4 bytes number).
> I'm working on a use case were there are many tables with blobs (on average not so large 32KB).
> I foresee that in 2-3 years time frame, the limit of overall blobs will be breached: more than 2^32 blobs.
>
> - Is there a way to change the OID limit?
> - Should we switch to a bytea implementation?
> - Are there any drawback of bytea except the maximum space?
Don't use large objects. They are only useful if
1) you have files larger than 1GB or
2) you need to stream writes
There are no such limitations if you use the "bytea" data type, and it is
much simpler to handle at the same time.
Yours,
Laurenz Albe
--
Cybertec | https://www.cybertec-postgresql.com
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-admin@postgresql.org
Cc: laurenz.albe@cybertec.at, donato.marrazzo@gmail.com
Subject: Re: How to get more than 2^32 BLOBs
In-Reply-To: <98e38782369def5f1fb865533ab22d828b442d78.camel@cybertec.at>
References: <CAC1K4Ghi6fa0ck4rrB4MSaOLas9MY4mnF-jNF4iwiy75UVj4iQ@mail.gmail.com> <98e38782369def5f1fb865533ab22d828b442d78.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