Re: Pgbouncer help

From: Jeff Janes <jeff(dot)janes(at)gmail(dot)com>
To: "Yelai, Ramkumar IN BLR STS" <ramkumar(dot)yelai(at)siemens(dot)com>
Cc: "pgsql-general(at)postgresql(dot)org" <pgsql-general(at)postgresql(dot)org>
Subject: Re: Pgbouncer help
Date: 2013-08-27 17:40:16
Message-ID: CAMkU=1wwk3nXOyaxuuZiJNAropzRHQxoPt-jrcHz_wwhvYpYWA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Tue, Aug 27, 2013 at 1:34 AM, Yelai, Ramkumar IN BLR STS
<ramkumar(dot)yelai(at)siemens(dot)com> wrote:
> HI
>
>
>
> In our current project, we are opening several postgresql connection. Few
> connections are frequently used and few are occasionally used. Hence we plan
> to adapt connection pool method to avoid more connection to open. We plan
> to use “Pgbouncer”. Most of the pgbouncer example shows how to configure,
> but they are not explaining how to use in C++.
>
>
>
> Please provide me a example, how to use it in C++.

pgbouncer is designed to look (to the client) just like a normal
postgresql server.

If you want all connections to the database to go through pgbouncer,
you can move the real server to a different port, and then start up
pgbouncer on that vacated port. In this case, the clients do not need
to make any changes at all to their configuration.

If you want to keep the real server on the same port as it currently
is and to use a special port to go through pgbouncer, then you need to
change the clients to use that new port number. You do this the same
way you would change the client to use a different port if that
different port were a regular postgresql server.

Cheers,

Jeff

In response to

  • Pgbouncer help at 2013-08-27 08:34:05 from Yelai, Ramkumar IN BLR STS

Responses

Browse pgsql-general by date

  From Date Subject
Next Message David Johnston 2013-08-27 18:27:06 Re: how to use aggregate functions in this case
Previous Message Paul Jungwirth 2013-08-27 17:07:20 Re: OLAP