Re: [HACKERS] Forcing current WAL file to be archived

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Jim C(dot) Nasby" <jnasby(at)pervasive(dot)com>, Simon Riggs <simon(at)2ndquadrant(dot)com>, Alvaro Herrera <alvherre(at)commandprompt(dot)com>
Cc: pgsql-hackers(at)postgresql(dot)org, pgsql-patches(at)postgresql(dot)org, Bruce Momjian <bruce(at)momjian(dot)us>, Hannu Krosing <hannu(at)skype(dot)net>
Subject: Re: [HACKERS] Forcing current WAL file to be archived
Date: 2006-08-15 22:42:17
Message-ID: 26543.1155681737@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers pgsql-patches

I wrote:
> It'd definitely be nicer that way, but given the current limitations of
> bootstrap mode I see no non-kluge way to make a built-in function have
> OUT parameters. (Hint: array_in doesn't work in bootstrap mode.)

Actually, that turns out not to be so hard to fix as I thought.
array_in only needs to work for the array types used in the core system
tables, and bootstrap.c already has a hard-wired table of that info ...
we only have to make it available to array_in. Which I just did.

So let's fix pg_xlogfile_name_offset() to have two OUT parameters
instead of returning a smushed-together string.

The reason I knew about the array_in problem was I'd tried to make some
other built-in function have OUT parameters ... I think it was probably
one of the ones that we currently have underneath system views. It
might be worthwhile converting some or all of these to use OUT
parameters and not need the crutch of an AS clause in the view:

pg_show_all_settings
pg_lock_status
pg_prepared_xact
pg_stat_file
pg_prepared_statement
pg_cursor
pg_timezonenames

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Greg Sabino Mullane 2006-08-15 22:44:51 Index bloat and the need to REINDEX
Previous Message Arturo Pérez 2006-08-15 22:22:53 Re: An Idea for planner hints

Browse pgsql-patches by date

  From Date Subject
Next Message Bruce Momjian 2006-08-16 00:30:18 Re: [PATCHES] Custom variable class segmentation fault
Previous Message korryd@enterprisedb.com 2006-08-15 20:12:33 Re: [PATCHES] PL instrumentation plugin and Rendezvous variable