On Fri, 2011-01-14 at 12:41 +0100, Magnus Hagander wrote:
> On Fri, Jan 14, 2011 at 12:15, Simon Riggs <simon@2ndquadrant.com> wrote:
> > On Fri, 2011-01-14 at 11:09 +0000, Simon Riggs wrote:
> >> Functions to control recovery, to aid PITR and Hot Standby.
> >> pg_is_xlog_replay_paused()
> >> pg_xlog_replay_pause()
> >> pg_xlog_replay_resume()
> >>
> >> recovery.conf parameter: pause_at_recovery_target (bool)
>
>
> Awesome, I've been waiting for these! :-)
>
> How hard would it be to have a pg_xlog_replay_until(<xlog location or
> timestamp>), to have it resume recovery up to that point and then
> pause again?
You can already do that for timestamps.
What you can't do is dynamically set recovery targets via functions,
since currently that is set via recovery.conf parameters. Which requires
restart.
Jaime has a separate patch about recovery targets as well, which does
some more of what you want.
Some things are straightforward, some things require overhaul of the
recovery.conf mechanisms, which is not the right time to do that, nor
have we even discussed let alone agreed what we would change it to.
-- Simon Riggs http://www.2ndQuadrant.com/books/PostgreSQL Development, 24x7 Support, Training and Services