[pgpool-general: 6700] Re: PGPool does not balance queries correctly. Java Application.
Tatsuo Ishii
ishii at sraoss.co.jp
Thu Sep 5 09:12:38 JST 2019
> Hello Everyone,
>
> I have four node postgresql with pgpol ahead:
>
> 0 node: master
> lb_weight: 0.25
>
> 1 node: slave1
> lb_weight: 0.25
>
> 2 node: slave2
> lb_weight: 0.25
>
> 3 node: slave3
> lb_weight: 0.25
>
> JBoss of a Java application is sending 99% queries only to the
> master node 0.
> PGPool and PostgreSQL servers are properly configured and i use method
> streaming replication. (pgpool.conf.sample-stream.)
> Do I need to validate some parameter in the java configuration to perform
> the correct balancing based on the lb_weight set?
>
> Obs:
> When I run a simple shell script (psql) perform queries from pgpool the
> balancing occurs perfectly
This suggests that queries sent from JBoss to Pgpool-II have different
patters from what psql does. If your Pgpool-II is version 4.0.x, you
could set:
log_client_messages = on
to see what queries are actually sent from JBoss. Please share the log
file after that.
Best regards,
--
Tatsuo Ishii
SRA OSS, Inc. Japan
English: http://www.sraoss.co.jp/index_en.php
Japanese:http://www.sraoss.co.jp
More information about the pgpool-general
mailing list