Re: [HACKERS] Confusing recovery message when target not hit

2016-06-12 Thread Michael Paquier
On Mon, Jun 13, 2016 at 9:53 AM, Thom Brown wrote: > On 12 June 2016 at 12:51, Michael Paquier wrote: >> >> On Sun, Jun 12, 2016 at 7:52 PM, Thom Brown wrote: >> > Aren't those already set by recoveryStopsBefore()? >> >> It is possible

Re: [HACKERS] Confusing recovery message when target not hit

2016-06-12 Thread Thom Brown
On 12 June 2016 at 12:51, Michael Paquier wrote: > On Sun, Jun 12, 2016 at 7:52 PM, Thom Brown wrote: > > Aren't those already set by recoveryStopsBefore()? > > It is possible to exit the main redo loop if a NULL record is found > after calling

Re: [HACKERS] Confusing recovery message when target not hit

2016-06-12 Thread Michael Paquier
On Sun, Jun 12, 2016 at 7:52 PM, Thom Brown wrote: > Aren't those already set by recoveryStopsBefore()? It is possible to exit the main redo loop if a NULL record is found after calling ReadRecord, in which case those would not be set, no? -- Michael -- Sent via pgsql-hackers

Re: [HACKERS] Confusing recovery message when target not hit

2016-06-12 Thread Thom Brown
On 11 June 2016 at 13:22, Michael Paquier wrote: > On Sat, Jun 11, 2016 at 9:44 AM, Thom Brown wrote: > > It may be the wrong way of going about it, but you get the idea of what > I'm > > suggesting we output instead. > > Surely things could be better.

Re: [HACKERS] Confusing recovery message when target not hit

2016-06-12 Thread Michael Paquier
On Sun, Jun 12, 2016 at 12:46 AM, David Steele wrote: > On 6/11/16 8:22 AM, Michael Paquier wrote: >> On Sat, Jun 11, 2016 at 9:44 AM, Thom Brown wrote: >>> It may be the wrong way of going about it, but you get the idea of what I'm >>> suggesting we output

Re: [HACKERS] Confusing recovery message when target not hit

2016-06-11 Thread David Steele
On 6/11/16 8:22 AM, Michael Paquier wrote: > On Sat, Jun 11, 2016 at 9:44 AM, Thom Brown wrote: >> It may be the wrong way of going about it, but you get the idea of what I'm >> suggesting we output instead. > > Surely things could be better. So +1 to be more verbose here. > > +

Re: [HACKERS] Confusing recovery message when target not hit

2016-06-11 Thread Michael Paquier
On Sat, Jun 11, 2016 at 9:44 AM, Thom Brown wrote: > It may be the wrong way of going about it, but you get the idea of what I'm > suggesting we output instead. Surely things could be better. So +1 to be more verbose here. +if (recoveryStopTime == 0) +

[HACKERS] Confusing recovery message when target not hit

2016-06-10 Thread Thom Brown
Hi all, When recovery_target_time is set, but recovery finishes before it reaches that time, it outputs "before 2000-01-01 00:00:00+00" to the .history file. This is because it uses recoveryStopTime, which is initialised to 0, but is never set, and is then passed to timestamptz_to_str, which