On 07/09/10 12:47, Simon Riggs wrote:
> The WAL is sent from master to standby in 8192 byte chunks, frequently
> including multiple commits. From standby, one reply per chunk. If we
> need to wait for apply while nothing else is received, we do.
Ok, thank you. The obvious performance problem is that even if you
define a transaction to use synchronization level 'recv', and there's no
other concurrent transactions running, you actually need to wait until
it's applied. If you have only one client, there is no difference
between the levels, you always get the same performance hit you get with
'apply'. With more clients, you get some benefit, but there's still
plenty of delays compared to the optimum.
Also remember that there can be a very big gap between when a record is
fsync'd and when it's applied, if the recovery needs to wait for a hot
standby transaction to finish.
-- Heikki Linnakangas EnterpriseDB http://www.enterprisedb.com