Skip site navigation (1) Skip section navigation (2)

Re: system views for walsender activity

From: Robert Haas <robertmhaas(at)gmail(dot)com>
To: Magnus Hagander <magnus(at)hagander(dot)net>
Cc: Simon Riggs <simon(at)2ndquadrant(dot)com>, Heikki Linnakangas <heikki(dot)linnakangas(at)enterprisedb(dot)com>, Josh Berkus <josh(at)agliodbs(dot)com>, Itagaki Takahiro <itagaki(dot)takahiro(at)gmail(dot)com>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: system views for walsender activity
Date: 2011-01-12 02:03:30
Message-ID: AANLkTi=mBL8sZDpx8gC35mJHxEV8q6K0qBbYJuw41TDH@mail.gmail.com (view raw or flat)
Thread:
Lists: pgsql-hackers
On Tue, Jan 11, 2011 at 7:24 AM, Magnus Hagander <magnus(at)hagander(dot)net> wrote:
>> No, do this at top
>>
>> if (walsnd->state == state)
>>  return;
>>
>> Keep spinlocks when actually setting it.

I think this is safe...

> Aha. Thanks for the pointers, pfa a new version.

...but I think you also need to take the spinlock when reading the value.

-- 
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

In response to

Responses

pgsql-hackers by date

Next:From: Robert HaasDate: 2011-01-12 02:06:09
Subject: Re: arrays as pl/perl input arguments [PATCH]
Previous:From: Cédric VillemainDate: 2011-01-12 02:00:12
Subject: Re: Allowing multiple concurrent base backups

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group