[Pgpool-general] understanding backend_weight

Tomasz Chmielewski mangoo at wpkg.org
Mon Nov 16 13:41:15 UTC 2009


Tatsuo Ishii wrote:
>> Out of curiosity, how would be such values handled?
>>
>> backend_hostname0 = 'postgres1'
>> backend_weight0 = 0
>>
>> backend_hostname1 = 'postgres2'
>> backend_weight1 = 1
>>
>> backend_hostname1 = 'postgres3'
>> backend_weight1 = 2
>>
>>
>> postgres1 should not get any reads.
>> postgres2 should get 33,3(3)% reads.
>> postgres2 should get 66,6(6)% reads.
>>
>> Is my reasoning correct?
> 
> Yes. See select_load_balancing_node() in child.c for more details.

OK, thanks for your help.


-- 
Tomasz Chmielewski
http://wpkg.org


More information about the Pgpool-general mailing list