Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1ZRyDN-0007Zx-07 for pgsql-hackers@arkaria.postgresql.org; Wed, 19 Aug 2015 07:55:17 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84) (envelope-from ) id 1ZRyDM-00025i-CS for pgsql-hackers@arkaria.postgresql.org; Wed, 19 Aug 2015 07:55:16 +0000 Received: from makus.postgresql.org ([2001:4800:1501:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84) (envelope-from ) id 1ZRyC4-0000O8-8Y for pgsql-hackers@postgresql.org; Wed, 19 Aug 2015 07:53:56 +0000 Received: from wagner.pp.ru ([178.63.209.18] helo=mx.wagner.pp.ru) by makus.postgresql.org with esmtp (Exim 4.84) (envelope-from ) id 1ZRyBo-0001xQ-DX for pgsql-hackers@postgresql.org; Wed, 19 Aug 2015 07:53:41 +0000 Received: from mail.wagner.pp.ru (unknown [192.168.217.131]) by mx.wagner.pp.ru (Postfix) with ESMTP id 5CF0114B4471 for ; Wed, 19 Aug 2015 10:53:08 +0300 (MSK) Received: from wagner.pp.ru (wifi [192.168.217.63]) by mail.wagner.pp.ru (Postfix) with ESMTPSA id 9026D211F1 for ; Wed, 19 Aug 2015 10:53:06 +0300 (MSK) Date: Wed, 19 Aug 2015 10:53:04 +0300 From: Victor Wagner To: pgsql-hackers@postgresql.org Subject: Re: Proposal: Implement failover on libpq connect level. Message-ID: <20150819075304.GF31302@wagner.pp.ru> References: <20150818041850.GA5092@wagner.pp.ru> <20150819070522.GB31302@wagner.pp.ru> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.23 (2014-03-12) X-Pg-Spam-Score: -2.5 (--) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-hackers Precedence: bulk Sender: pgsql-hackers-owner@postgresql.org On 2015.08.19 at 12:55:15 +0530, Amit Kapila wrote: > > I think that failover procedure should begin before first connection is > > ever established. > > > > As far as I understand, failover gets initiated once the master server goes > down or is not accessible due to some reason, so for such cases if you > have the connection to both the servers then it might not work. Master server might go down when client is not started yet. And when client starts up, it has to find out which server to connect now. Consider point-of-sale terminals, bank offices or anything else, which do not work round the clock. Clerk comes to his workplace in the morning, switches on terminal and inserts her smartcard to authorize with server. She doesn't need to know what server name is and where it is located. Either application finds the server automatically, or support engineer has to be called to fix things. Moreover, in some situations restart of application (or even client terminal) is acceptable price for failover, as long as there is no need to manually fix the configuration. -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers