Hi,
On 2018-09-14 16:13:46 +0200, Tomas Vondra wrote:
> >
> > I suspect the proper fix would be to have a new HEAP_INSERT_NO_LOGICAL
> > option, and specify that in raw_heap_insert() iff
> > RelationIsLogicallyLogged(state->rs_old_rel) or something like that.
> >
> > Attached is a *prototype* patch of that approach. Without the code
> > level changes the addition to test_decoding's rewrite.sql trigger the
> > bug, after it they're fixed.
> >
> >
> > The only reason the scenario I was debugging hit this was that there was
> > a cluster wide VACUUM FULL a couple times a day, and replication was
> > several hours behind due to slow network / receiving side.
> >
> >
> > Now I'm having a beer outside.
> Yeah, that seems like a bad idea. That error already caught a couple of
> bugs (including da10d6a8a9 and this one), and I have a hunch those are
> not the last ones.
One problem with this is that that means upgrading won't fix an existing
instance of the problem, but turning the ERROR into a WARNING would. I
personally think that's *NOT* enough justification for relaxing the
error, given that recreating the slot would fix the issue, but I see how
other people can reasonably differ. I can't really see a reasonably
complex approach that solves the issue in a "cake but have it too"
way...
> After discarding 30 theories? Have two.
I will neither confirm nor deny. ;)
Greetings,
Andres Freund