Re: Relation cache invalidation on replica - Mailing list pgsql-hackers

From Andres Freund
Subject Re: Relation cache invalidation on replica
Date
Msg-id 20160227012318.fnjtmtg5q5qvllqk@alap3.anarazel.de
Whole thread Raw
In response to Re: Relation cache invalidation on replica  (Simon Riggs <simon@2ndQuadrant.com>)
Responses Re: Relation cache invalidation on replica
List pgsql-hackers
On 2016-02-27 01:16:34 +0000, Simon Riggs wrote:
> If the above is true, then the proposed fix wouldn't work either.
> 
> No point in sending a cache invalidation message on the standby if you
> haven't also written WAL, since the catalog re-read would just see the old
> row.
> 
> heap_inplace_update() does write WAL, which blows away the starting premise.

I'm not following here. heap_inplace_update() indeed writes WAL, but it
does *NOT* (and may not) assign an xid. Thus we're not emitting the
relcache invalidation queued in DefineIndex(), as
RecordTransactionCommit() currently skips emitting a commit record if
there's no xid.


> So I'm not seeing this as an extant bug in an open source version of
> PostgreSQL, in my current understanding.

But the first message in the thread demonstrated a reproducible problem?


Andres



pgsql-hackers by date:

Previous
From: Simon Riggs
Date:
Subject: Re: Relation cache invalidation on replica
Next
From: Simon Riggs
Date:
Subject: Re: Relation cache invalidation on replica