Re: Doubt in pgbouncer

2021-11-03 Thread Ninad Shah
There is no equation to determine the best value. It depends on your
environment.


Regards,
Ninad Shah

On Wed, 3 Nov 2021 at 19:18, Rama Krishnan  wrote:

>
> Hi All,
>
> What is the limit value for fixing connection timeout issues?
>
> As i searched in google and verified pgbouncer document
> client_login_timeout
>
> If a client connects but does not manage to log in in this amount of time,
> it will be disconnected. Mainly needed to avoid dead connections stalling
> SUSPEND and thus online restart. [seconds]
>
> Default: 60.0
>
> Can you pls suggest the best value ? or how to decide this parameter value
>
>
>
> Regards
>
> A.Rama Krishnan
>


Doubt in pgbouncer

2021-11-03 Thread Rama Krishnan
Hi All,

What is the limit value for fixing connection timeout issues?

As i searched in google and verified pgbouncer document
client_login_timeout

If a client connects but does not manage to log in in this amount of time,
it will be disconnected. Mainly needed to avoid dead connections stalling
SUSPEND and thus online restart. [seconds]

Default: 60.0

Can you pls suggest the best value ? or how to decide this parameter value



Regards

A.Rama Krishnan


Re: Doubt on pgbouncer

2021-07-22 Thread Rama Krishnan
Ok, thank you sir

On Thu, 22 Jul, 2021, 20:23 Ninad Shah,  wrote:

> Pgbouncer doesn't provide such a functionality. Kindly consider using
> pgpool.
>
> On Thu, 22 Jul 2021 at 15:58, Ganesh Korde  wrote:
>
>> Try using HAProxy.
>>
>> Regards,
>> Ganesh Korde.
>>
>> On Sat, 3 Jul 2021, 9:06 pm Rama Krishnan,  wrote:
>>
>>>
>>> Hi Team,
>>>
>>> How can I split read and write queries using pgbouncer
>>>
>>> Regards
>>>
>>> A.Rama Krishnan
>>>
>>>
>>> 
>>>  Virus-free.
>>> www.avast.com
>>> 
>>> <#m_-3565042833678223020_m_2585993038985863414_m_3619964688060668000_DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2>
>>>
>>


Re: Doubt on pgbouncer

2021-07-22 Thread Ninad Shah
Pgbouncer doesn't provide such a functionality. Kindly consider using
pgpool.

On Thu, 22 Jul 2021 at 15:58, Ganesh Korde  wrote:

> Try using HAProxy.
>
> Regards,
> Ganesh Korde.
>
> On Sat, 3 Jul 2021, 9:06 pm Rama Krishnan,  wrote:
>
>>
>> Hi Team,
>>
>> How can I split read and write queries using pgbouncer
>>
>> Regards
>>
>> A.Rama Krishnan
>>
>>
>> 
>>  Virus-free.
>> www.avast.com
>> 
>> <#m_2585993038985863414_m_3619964688060668000_DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2>
>>
>


Re: Doubt on pgbouncer

2021-07-22 Thread Ganesh Korde
Try using HAProxy.

Regards,
Ganesh Korde.

On Sat, 3 Jul 2021, 9:06 pm Rama Krishnan,  wrote:

>
> Hi Team,
>
> How can I split read and write queries using pgbouncer
>
> Regards
>
> A.Rama Krishnan
>
>
> 
>  Virus-free.
> www.avast.com
> 
> <#m_3619964688060668000_DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2>
>


Re: Doubt on pgbouncer

2021-07-07 Thread Merlin Moncure
On Sat, Jul 3, 2021 at 10:36 AM Rama Krishnan  wrote:
>
>
> Hi Team,
>
> How can I split read and write queries using pgbouncer

Check out pgbouncer-rr.  I haven't used it, but it may do what you need.

merlin




Re: Doubt on pgbouncer

2021-07-04 Thread Rama Krishnan
Thank you for the clarification.

On Sat, 3 Jul, 2021, 23:20 Ben Chobot,  wrote:

> Rama Krishnan wrote on 7/3/21 8:35 AM:
>
>
> Hi Team,
>
> How can I split read and write queries using pgbouncer
>
>
> You do it with your application. Make a pgbouncer database for read/write
> queries and point it at your postgresql primary, and then make a second
> pgbouncer database for read-only queries and point it at a replica. Have
> your application connect to the proper database, depending upon its needs.
>
> It's not transparent, but it is effective.
>


Re: Doubt on pgbouncer

2021-07-03 Thread Ben Chobot

Rama Krishnan wrote on 7/3/21 8:35 AM:


Hi Team,

How can I split read and write queries using pgbouncer


You do it with your application. Make a pgbouncer database for 
read/write queries and point it at your postgresql primary, and then 
make a second pgbouncer database for read-only queries and point it at a 
replica. Have your application connect to the proper database, depending 
upon its needs.


It's not transparent, but it is effective.


Re: Doubt on pgbouncer

2021-07-03 Thread Rama Krishnan
Hi Bruce

Thank you for the clarification. Can you pls share any links or docs about
my doubt that can be helpful for me further information

On Sat, 3 Jul, 2021, 21:21 Bruce Momjian,  wrote:

> On Sat, Jul  3, 2021 at 09:05:58PM +0530, Rama Krishnan wrote:
> >
> > Hi Team,
> >
> > How can I split read and write queries using pgbouncer
>
> No.  I think only PgPool can do that because it parses the SQL.
>
> --
>   Bruce Momjian  https://momjian.us
>   EDB  https://enterprisedb.com
>
>   If only the physical world exists, free will is an illusion.
>
>


Re: Doubt on pgbouncer

2021-07-03 Thread Bruce Momjian
On Sat, Jul  3, 2021 at 09:05:58PM +0530, Rama Krishnan wrote:
> 
> Hi Team,
> 
> How can I split read and write queries using pgbouncer

No.  I think only PgPool can do that because it parses the SQL.

-- 
  Bruce Momjian  https://momjian.us
  EDB  https://enterprisedb.com

  If only the physical world exists, free will is an illusion.





Doubt on pgbouncer

2021-07-03 Thread Rama Krishnan
Hi Team,

How can I split read and write queries using pgbouncer

Regards

A.Rama Krishnan


Virus-free.
www.avast.com

<#DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2>


Re: Doubt in pgbouncer

2020-10-02 Thread Achilleas Mantzios

On 2/10/20 9:50 π.μ., Fabio Pardi wrote:

Hi Rama,

On 02/10/2020 01:42, Rama Krishnan wrote:

Hi Friends,

By using pg bouncer can we split read and queries



pgbouncer is just a connection pooler.

The logic where to send the reads and where the writes, should be in our 
application.
yeah reading back some comments over the github on various issues, the pgbouncer hackers were of the philosophy that pgbouncer should remain as query agnostic as possible, in the sense that it should 
not investigate the content of the queries. Those had to do with classic problems like search_path in transaction mode (some PR's were rejected because of that).

You might find this interesting : https://github.com/awslabs/pgbouncer-rr-patch


regards,

fabio pardi



--
Achilleas Mantzios
IT DEV Lead
IT DEPT
Dynacom Tankers Mgmt



Re: Doubt in pgbouncer

2020-10-02 Thread David G. Johnston
On Thursday, October 1, 2020, Fabio Pardi  wrote:

> Hi Rama,
>
> On 02/10/2020 01:42, Rama Krishnan wrote:
>
> Hi Friends,
>
> By using pg bouncer can we split read and queries
>
>
> pgbouncer is just a connection pooler.
>
> The logic where to send the reads and where the writes, should be in our
> application.
>

Seems as if pgPool is at least worth considering...

David J.


Re: Doubt in pgbouncer

2020-10-02 Thread Fabio Pardi
Hi Rama,

On 02/10/2020 01:42, Rama Krishnan wrote:
> Hi Friends, 
>
> By using pg bouncer can we split read and queries
>

pgbouncer is just a connection pooler.

The logic where to send the reads and where the writes, should be in our 
application.

regards,

fabio pardi


Re: Doubt in pgbouncer

2020-10-01 Thread Rama Krishnan
Yeah.  Rob

On Fri, 2 Oct, 2020, 05:14 Rob Sargent,  wrote:

>
>
> > On Oct 1, 2020, at 5:42 PM, Rama Krishnan  wrote:
> >
> > Hi Friends,
> >
> > By using pg bouncer can we split read and queries
> >
> > Thank
> > Rk
>
> Did you mean reads vs writes?
>


Re: Doubt in pgbouncer

2020-10-01 Thread Rama Krishnan
Yeah rob can  we spilt read/write queries using pgbouncer

On Fri, 2 Oct, 2020, 08:43 Rama Krishnan,  wrote:

> Yeah.  Rob
>
> On Fri, 2 Oct, 2020, 05:14 Rob Sargent,  wrote:
>
>>
>>
>> > On Oct 1, 2020, at 5:42 PM, Rama Krishnan  wrote:
>> >
>> > Hi Friends,
>> >
>> > By using pg bouncer can we split read and queries
>> >
>> > Thank
>> > Rk
>>
>> Did you mean reads vs writes?
>>
>


Re: Doubt in pgbouncer

2020-10-01 Thread Rob Sargent



> On Oct 1, 2020, at 5:42 PM, Rama Krishnan  wrote:
> 
> Hi Friends, 
> 
> By using pg bouncer can we split read and queries
> 
> Thank
> Rk

Did you mean reads vs writes?




Doubt in pgbouncer

2020-10-01 Thread Rama Krishnan
Hi Friends,

By using pg bouncer can we split read and queries

Thank
Rk