Re: tuptoaster.c must *not* use SnapshotAny

From: Jan Wieck <janwieck(at)yahoo(dot)com>
To: Hiroshi Inoue <Inoue(at)tpf(dot)co(dot)jp>
Cc: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Jan Wieck <janwieck(at)yahoo(dot)com>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: tuptoaster.c must *not* use SnapshotAny
Date: 2002-01-18 06:06:11
Message-ID: 200201180606.g0I66Bg05438@saturn.janwieck.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hiroshi Inoue wrote:
[Charset iso-2022-jp unsupported, skipping...]
> Though I've often seen the reference to bytea BLOB
> I remember no clear negation. Don't we have to negate
> it clearly from the first ?

Any datatype that has the potential to be loaded into memory
entirely by the backend is dangerous. It leads to problems
like "out of swapspace", which aren't really funny in
production.

We need something that is restricted to streaming access
only. Yet, it needs to have copy semantics.

That means to me, that this will not only be a new datatype,
but some more infrastructure too. We need INSERT ...
RETURNING ... where the values for BLOBs are given as
NEW_BLOB() and the returned identifier is subsequently used
to open the created BLOBs for writing and pump the data in.

We need heap access level tuple support to duplicate those
values on INSERT ... SELECT, to remove them on DELETE and to
manipulate them on UPDATE.

We need new functionality in procedural languages to support
streaming in and out of these guy's, where the actual data is
buffered in temp files and only blob identifiers passed
around.

I see the final storage of blob data to happen in the toast
table, sliced, diced and handy (most probably not
compressed). But I don't see an easy way to abuse the bytea
datatype for real blob support.

Jan

--

#======================================================================#
# It's easier to get forgiveness for being wrong than for being right. #
# Let's break this rule - forgive me. #
#================================================== JanWieck(at)Yahoo(dot)com #

_________________________________________________________
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Joe Conway 2002-01-18 06:16:34 Re: tuptoaster.c must *not* use SnapshotAny
Previous Message Bruce Momjian 2002-01-18 05:54:09 Re: age() function?