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

Re: [HACKERS] Streaming replication document improvements

From: Fujii Masao <masao(dot)fujii(at)gmail(dot)com>
To: Robert Haas <robertmhaas(at)gmail(dot)com>
Cc: Josh Berkus <josh(at)agliodbs(dot)com>, Kevin Grittner <Kevin(dot)Grittner(at)wicourts(dot)gov>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Heikki Linnakangas <heikki(dot)linnakangas(at)enterprisedb(dot)com>, pgsql-docs(at)postgresql(dot)org, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: [HACKERS] Streaming replication document improvements
Date: 2010-04-20 09:47:51
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-docspgsql-hackers
On Tue, Apr 20, 2010 at 11:04 AM, Robert Haas <robertmhaas(at)gmail(dot)com> wrote:
> Instead of doing this, could we just change the logic in InitPostgres?
> Current logic says we hit the connection limit if:
>        if (!am_superuser &&
>                ReservedBackends > 0 &&
>                !HaveNFreeProcs(ReservedBackends))
> Couldn't we just change this to:
>        if ((!am_superuser || am_walsender) &&
>                ReservedBackends > 0 &&
>                !HaveNFreeProcs(ReservedBackends))
> Seems like that'd be a whole lot simpler, if it'll do the job...

It's very simple, but prevents superuser replication connection
from being established when connection limit exceeds for
non-superusers. It seems strange to me that superuser cannot use
superuser_reserved_connections slots. If we'd like to forbid
replication connection to use the slots, I think that we should
just get rid of a superuser privilege from it instead.


Fujii Masao
NTT Open Source Software Center

In response to


pgsql-docs by date

Next:From: Robert HaasDate: 2010-04-20 10:52:11
Subject: Re: [HACKERS] Streaming replication document improvements
Previous:From: Robert HaasDate: 2010-04-20 02:04:59
Subject: Re: [HACKERS] Streaming replication document improvements

pgsql-hackers by date

Next:From: Fujii MasaoDate: 2010-04-20 09:53:59
Subject: Re: Streaming replication and a disk full in primary
Previous:From: Takahiro ItagakiDate: 2010-04-20 08:34:09
Subject: Re: [GENERAL] trouble with to_char('L')

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