> >>> In synchronous mode, pg_receivexlog should have similar logic as
> walreceiver does.
> >>
> >> OK. I understand that removing --fsync-interval has no problem.
> >
> > +1 for adding something like --synchronous option. To me,
> > it sounds walreceiver-compatible mode rather than synchronous.
> >
> >>> Better to add a new "notify" message type. And pg_recevexlog should
> be prepared to receive it at any time. The status might change on the
> fly, if the server's configuration is reloaded.
> >>
> >> OK. I'll consider it.
> >
> > I don't think that's good idea because it prevents us from using
> > pg_receivexlog as async walreceiver (i.e., received WAL data is
> > fsynced and feedback is sent back to the server soon, but transaction
> > commit in the server doesn't wait for the feedback).
> 
> Sync rep works by setting parameters on the master. Standby servers send
> replies by default, though you can turn replies off.
> 
> pg_receivexlog should work the same, but can't do this because it doesn't
> know the fsync position unless it fsyncs.
> 
> So its not appropriate to have an option called "--synchronous" in the
> same way that there is no parameter called "synchronous" on the standby,
> for good reason.
> 
> A new parameter to send feedback should be called --feedback A second
> parameter to decide whether to fsync should be called --fsync
> 
> if (feedback && fsync)
>    send fsynced LSN
> else if (feedback)
>    send received LSN
> ; /* else send no feedback */

Thanks for the comment.

The patch cannot be applied to HEAD cleanly so I updated.

>So its not appropriate to have an option called "--synchronous" in the same 
>way that there is no >parameter called "synchronous" on the standby, for good 
>reason.

In case of gathering options to one option, 
change the name "--synchronous" to other name solves the problem ?

>A new parameter to send feedback should be called --feedback 
>A second parameter to decide whether to fsync should be called --fsync

I think keep using "--reply-fsync" and "--fsync-interval" is better than make 
new options.
Thought?

Regards,

--
Furuya Osamu

Attachment: pg_receivexlog-fsync-feedback-v6.patch
Description: pg_receivexlog-fsync-feedback-v6.patch

-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

Reply via email to