Re: [PATCH] Largeobject access controls

From: KaiGai Kohei <kaigai(at)ak(dot)jp(dot)nec(dot)com>
To: Itagaki Takahiro <itagaki(dot)takahiro(at)oss(dot)ntt(dot)co(dot)jp>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: [PATCH] Largeobject access controls
Date: 2009-08-28 06:09:08
Message-ID: 4A977484.5040307@ak.jp.nec.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Itagaki Takahiro wrote:
> KaiGai Kohei <kaigai(at)ak(dot)jp(dot)nec(dot)com> wrote:
>
>> The pg_largeobject system catalog is reworked to manage its metadata.
>>
>> CATALOG(pg_largeobject,2613)
>> {
>> Oid loowner; /* OID of the owner */
>> Oid lochunk; /* OID of the data chunks */
>> aclitem loacl[1]; /* access permissions */
>> } FormData_pg_largeobject;
>>
>> Actual data chunks are stored in the toast relation of pg_largeobject,
>> and its chunk_id is stored in the pg_largeobject.lochunk.
>
> A bit acrobatic, but insteresting idea.
>
> I have some random comments:
>
> * Do you measure performance of the new LO implementation?
> AFAIK, Users expect performance benefits to LO; TOASTed
> bytea slows down when the size of data is 100KB or greater
> even if they don't use random seeks.

Not yet. Can you recommend commonly-used workload?

> * We might take care of DROP ROLE and REASSIGN/DROP OWNED.
> Or, we might have large object without owner.
> It might require full-scanning of pg_largeobject table,
> but we can accept it because the size of pg_largeobject
> will be smaller; we have actual data out of the table.

I think it should be implemented using the dependency mechanism.
It requires full-scanning on the pg_shdepend tables, but it has
been accepted.

> * Don't we also need "ALTER LARGE OBJECT <oid> OWNER TO <user>"
> for consistency?

Agreed. It will be also necessary to implement REASSIGN OWNED.

Thanks,
--
OSS Platform Development Division, NEC
KaiGai Kohei <kaigai(at)ak(dot)jp(dot)nec(dot)com>

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Greg Smith 2009-08-28 06:35:21 Re: 8.5 release timetable, again
Previous Message Itagaki Takahiro 2009-08-28 05:52:33 Re: [PATCH] Largeobject access controls