Re: TABLESPACE and directory for Foreign tables? - Mailing list pgsql-hackers

From Magnus Hagander
Subject Re: TABLESPACE and directory for Foreign tables?
Date
Msg-id CABUevEzfV4rbmU2gP6R9OAhzgTZ9Fu4tgSK-WW=BNPiFATM9wg@mail.gmail.com
Whole thread Raw
In response to Re: TABLESPACE and directory for Foreign tables?  (Josh Berkus <josh@agliodbs.com>)
List pgsql-hackers
On Mon, May 5, 2014 at 8:17 PM, Josh Berkus <josh@agliodbs.com> wrote:
On 05/05/2014 10:53 AM, Tom Lane wrote:
> Josh Berkus <josh@agliodbs.com> writes:
>> I'm working with the cstore_fdw project, which has an interesting
>> property for an FDW: the FDW itself creates the files which make up the
>> database.   This raises a couple of questions:
>
>> 1) Do we want to establish a standard directory for FDWs which create
>> files, such as $PGDATA/base/{database-oid}/fdw/ ?  Or would we want to
>> leave it up to each FDW to decide?
>
> I think we ought to vigorously discourage FDWs from storing any files
> inside $PGDATA.  This cannot lead to anything except grief.  Just for
> starters, what will operations such as pg_basebackup do with them?

That was one advantage to putting them in PGDATA; you get a copy of the
files with pg_basebackup.  Of course, they don't replicate after that,
but they potentially could, in the future, with Logical Streaming
Replication.

Presumably they'd also be inconsistent? And as such not really useful unless you actually shut the database down before you back it up (e.g. don't use pg_basebackup)?


--
 Magnus Hagander
 Me: http://www.hagander.net/
 Work: http://www.redpill-linpro.com/

pgsql-hackers by date:

Previous
From: Josh Berkus
Date:
Subject: Re: TABLESPACE and directory for Foreign tables?
Next
From: Andres Freund
Date:
Subject: Re: TABLESPACE and directory for Foreign tables?