From: | Noah Misch <noah(at)leadboat(dot)com> |
---|---|
To: | Michael Paquier <michael(at)paquier(dot)xyz> |
Cc: | Robert Haas <robertmhaas(at)gmail(dot)com>, Christoph Berg <myon(at)debian(dot)org>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org> |
Subject: | Re: pgsql: Move tablespace path re-creation from the makefiles to pg_regres |
Date: | 2021-03-25 02:56:59 |
Message-ID: | 20210325025659.GA4017435@rfd.leadboat.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-committers pgsql-hackers |
On Thu, Mar 25, 2021 at 07:44:02AM +0900, Michael Paquier wrote:
> On Wed, Mar 24, 2021 at 10:50:50AM -0400, Robert Haas wrote:
> > On Wed, Mar 24, 2021 at 5:56 AM Christoph Berg <myon(at)debian(dot)org> wrote:
> >> Maybe creating the tablespace directory from within the testsuite
> >> would suffice?
> >>
> >> CREATE TABLE foo (t text);
> >> COPY foo FROM PROGRAM 'mkdir @testtablespace@';
> >> CREATE TABLESPACE regress_tblspace LOCATION '@testtablespace@';
> >
> > Would that work on Windows?
That would entail forbidding various shell metacharacters in @testtablespace(at)(dot)
One could avoid imposing such a restriction by adding a mkdir() function to
regress.c and writing it like:
CREATE FUNCTION mkdir(text)
RETURNS void AS '@libdir@/regress(at)DLSUFFIX@', 'regress_mkdir'
LANGUAGE C STRICT\;
REVOKE ALL ON FUNCTION mkdir FROM public;
SELECT mkdir('@testtablespace@');
CREATE TABLESPACE regress_tblspace LOCATION '@testtablespace@';
> I doubt that all the Windows environments would be able to get their
> hands on that.
> And I am not sure either that this would work when it
> comes to the CI case, again on Windows.
How might a CI provider break that?
From | Date | Subject | |
---|---|---|---|
Next Message | Michael Paquier | 2021-03-25 07:12:18 | pgsql: Sanitize the term "combo CID" in code comments |
Previous Message | Fujii Masao | 2021-03-25 02:27:41 | pgsql: Fix bug in WAL replay of COMMIT_TS_SETTS record. |
From | Date | Subject | |
---|---|---|---|
Next Message | Michael Paquier | 2021-03-25 03:47:50 | Re: multi-install PostgresNode |
Previous Message | Masahiro Ikeda | 2021-03-25 02:50:12 | Re: About to add WAL write/fsync statistics to pg_stat_wal view |