From: | Dilip Kumar <dilipbalaut(at)gmail(dot)com> |
---|---|
To: | Yugo NAGATA <nagata(at)sraoss(dot)co(dot)jp> |
Cc: | Masahiko Sawada <sawada(dot)mshk(at)gmail(dot)com>, Robert Haas <robertmhaas(at)gmail(dot)com>, Bharath Rupireddy <bharath(dot)rupireddyforpostgres(at)gmail(dot)com>, Kyotaro Horiguchi <horikyota(dot)ntt(at)gmail(dot)com>, Simon Riggs <simon(at)2ndquadrant(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org> |
Subject: | Re: Is Recovery actually paused? |
Date: | 2021-01-28 04:25:42 |
Message-ID: | CAFiTN-t+zW3Ldu2bmqRUuN_h1h-ri2OAcPiDSvMBKv9_sFkX5A@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Wed, Jan 27, 2021 at 2:28 PM Dilip Kumar <dilipbalaut(at)gmail(dot)com> wrote:
>
> On Wed, Jan 27, 2021 at 2:06 PM Yugo NAGATA <nagata(at)sraoss(dot)co(dot)jp> wrote:
> >
> > On Wed, 27 Jan 2021 13:29:23 +0530
> > Dilip Kumar <dilipbalaut(at)gmail(dot)com> wrote:
> >
> > > On Wed, Jan 27, 2021 at 12:50 PM Masahiko Sawada <sawada(dot)mshk(at)gmail(dot)com> wrote:
> > > >
> > > > On Tue, Jan 26, 2021 at 2:00 AM Robert Haas <robertmhaas(at)gmail(dot)com> wrote:
> > > > >
> > > > > On Sat, Jan 23, 2021 at 6:10 AM Bharath Rupireddy
> > > > > <bharath(dot)rupireddyforpostgres(at)gmail(dot)com> wrote:
> > > > > > +1 to just show the recovery pause state in the output of
> > > > > > pg_is_wal_replay_paused. But, should the function name
> > > > > > "pg_is_wal_replay_paused" be something like
> > > > > > "pg_get_wal_replay_pause_state" or some other? To me, when "is" exists
> > > > > > in a function, I expect a boolean output. Others may have better
> > > > > > thoughts.
> > > > >
> > > > > Maybe we should leave the existing function pg_is_wal_replay_paused()
> > > > > alone and add a new one with the name you suggest that returns text.
> > > > > That would create less burden for tool authors.
> > > >
> > > > +1
> > > >
> > >
> > > Yeah, we can do that, I will send an updated patch soon.
> >
> > This means pg_is_wal_replay_paused is left without any change and this
> > returns whether pause is requested or not? If so, it seems good to modify
> > the documentation of this function in order to note that this could not
> > return the actual pause state.
>
> Yes, we can say that it will return true if the replay pause is
> requested. I am changing that in my new patch.
I have modified the patch, changes
- I have added a new interface pg_get_wal_replay_pause_state to get
the pause request state
- Now, we are not waiting for the recovery to actually get paused so I
think it doesn't make sense to put a lot of checkpoints to check the
pause requested so I have removed that check from the
recoveryApplyDelay but I think it better we still keep that check in
the WaitForWalToBecomeAvailable because it can wait forever before the
next wal get available.
--
Regards,
Dilip Kumar
EnterpriseDB: http://www.enterprisedb.com
Attachment | Content-Type | Size |
---|---|---|
v8-0001-Provide-a-new-interface-to-get-the-recovery-pause.patch | application/octet-stream | 12.7 KB |
From | Date | Subject | |
---|---|---|---|
Next Message | japin | 2021-01-28 04:37:03 | Re: Support ALTER SUBSCRIPTION ... ADD/DROP PUBLICATION ... syntax |
Previous Message | Bharath Rupireddy | 2021-01-28 04:22:11 | Re: Support ALTER SUBSCRIPTION ... ADD/DROP PUBLICATION ... syntax |