Received: from maia.hub.org (maia-2.hub.org [200.46.204.251]) by mail.postgresql.org (Postfix) with ESMTP id CEA871337B93 for ; Fri, 21 Jan 2011 13:01:02 -0400 (AST) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.251]) (amavisd-maia, port 10024) with ESMTP id 85031-07 for ; Fri, 21 Jan 2011 17:00:55 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from outmail149120.authsmtp.net (outmail149120.authsmtp.net [62.13.149.120]) by mail.postgresql.org (Postfix) with ESMTP id 3664C1337B90 for ; Fri, 21 Jan 2011 13:00:55 -0400 (AST) Received: from mail-c194.authsmtp.com (mail-c194.authsmtp.com [62.13.128.121]) by punt6.authsmtp.com (8.14.2/8.14.2/Kp) with ESMTP id p0LH0oxJ004415; Fri, 21 Jan 2011 17:00:50 GMT Received: from [192.168.0.6] (79-71-91-175.dynamic.dsl.as9105.com [79.71.91.175]) (authenticated bits=0) by mail.authsmtp.com (8.14.2/8.14.2) with ESMTP id p0LH0gf1054088; Fri, 21 Jan 2011 17:00:42 GMT Subject: Re: Sync Rep for 2011CF1 From: Simon Riggs To: Magnus Hagander Cc: Heikki Linnakangas , pgsql-hackers@postgresql.org In-Reply-To: References: <1295127631.3282.100.camel@ebony> <4D397FE4.2020709@enterprisedb.com> <1295616270.1803.10799.camel@ebony> Content-Type: text/plain; charset="UTF-8" Date: Fri, 21 Jan 2011 17:00:41 +0000 Message-ID: <1295629241.1803.11965.camel@ebony> Mime-Version: 1.0 X-Mailer: Evolution 2.28.3 Content-Transfer-Encoding: 7bit X-Server-Quench: fb79ce12-257f-11e0-80b9-0022640b883e X-AuthReport-Spam: If SPAM / abuse - report it at: http://www.authsmtp.com/abuse X-AuthRoute: OCdxZQATClZOTQEd DAteCiN5VAwpPBRK HVkIKg5MJUcNSQVJ NksadRtFagRbZ1hf HGQLWlVEUVp7WWN/ bwkfagxDZUtQVgR0 UU9MXVdaExpoT1wB emYeBU9zdwBCeHZ4 K0FjWHEVChZ9fBUo Q0xJF2gBM3phaTUf TUhYJQpJcANIfBlB agJ3XHBYLwdSbGoL PyYYHB0LBgAXEzVT SUk3IEpaT0ERVmRk HkkpM2xH X-Authentic-SMTP: 61633235383639.1015:706 X-AuthFastPath: 0 (Was 255) X-AuthVirus-Status: No virus detected - but ensure you scan with your own anti-virus system. X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.9 tagged_above=-5 required=5 tests=BAYES_00=-1.9 X-Spam-Level: X-Archive-Number: 201101/2125 X-Sequence-Number: 179962 On Fri, 2011-01-21 at 14:34 +0100, Magnus Hagander wrote: > On Fri, Jan 21, 2011 at 14:24, Simon Riggs wrote: > > On Fri, 2011-01-21 at 14:45 +0200, Heikki Linnakangas wrote: > >> * it seems like overkill to not let clients to even connect when > >> allow_standalone_primary=off and no synchronous standbys are available. > >> What if you just want to run a read-only query? > > > > That's what Aidan requested, I agreed and so its there. You're using > > sync rep because of writes, so you have a read-write app. If you allow > > connections then half of the app will work, half will not. Half-working > > isn't very useful, as Aidan eloquently explained. If your app is all > > read-only you wouldn't be using sync rep anyway. That's the argument, > > but I've not got especially strong feelings it has to be this way. > > > > Perhaps discuss that on a separate thread? See what everyone thinks? > > I'll respond here once, and we'll see if more people want to comment > then we can move it :-) > > Doesn't this make a pretty strange assumption - namely that you have a > single application? We support multiple databases, and multiple users, > and multiple pretty much anything - in most cases, people deploy > multiple apps. (They may well be part of the same "solution" or > whatever you want to call it, but parts may well be readonly - like a > reporting app, or even just a monitoring client) There are various problems whatever we do. If we don't like one way, we must balance that by judging what happens if we do things the other way. -- Simon Riggs http://www.2ndQuadrant.com/books/ PostgreSQL Development, 24x7 Support, Training and Services