From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | Torsten Förtsch <torsten(dot)foertsch(at)gmx(dot)net> |
Cc: | Andy Colson <andy(at)squeakycode(dot)net>, pgsql-general(at)postgresql(dot)org |
Subject: | Re: pg_stat_replication in 9.3 |
Date: | 2014-09-14 16:55:29 |
Message-ID: | 693.1410713729@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
=?UTF-8?B?VG9yc3RlbiBGw7ZydHNjaA==?= <torsten(dot)foertsch(at)gmx(dot)net> writes:
> The replicas are far away, intercontinental far. I am not complaining
> that the replica looses the connection. What makes me wonder is that
> within a transaction, pg_stat_replication can forget rows but cannot
> acquire new ones. I'd think it should be either report the state at the
> beginning of the transaction like now() or the current state like
> clock_timestamp(). But currently it's reporting half the current state.
Are you watching the state in a loop inside a single plpgsql function?
If so, I wonder whether the problem is that the plpgsql function's
snapshot isn't changing. From memory, marking the function VOLATILE
would help if that's the issue.
regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | Torsten Förtsch | 2014-09-14 20:47:41 | Re: pg_stat_replication in 9.3 |
Previous Message | Torsten Förtsch | 2014-09-14 14:59:07 | Re: pg_stat_replication in 9.3 |