New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

loadBalanceHosts property is documented and it is not implemented #912

Closed
vlsi opened this Issue Aug 8, 2017 · 6 comments

Comments

Projects
None yet
3 participants
@vlsi
Member

vlsi commented Aug 8, 2017

Default value: false (==use failover hosts in order)
Documentation:

If disabled hosts are connected in the given order. If enabled hosts are chosen randomly from the set of suitable candidates

The property is never used, thus "load balancing" is just missing.

PS. I do not mean it should be there, however I just noticed an unused property while reviewing "failover" code.

@vlsi

This comment has been minimized.

Member

vlsi commented Aug 8, 2017

Ah, it is used in a String form in

loadBalance = parseBoolean(info.getProperty("loadBalanceHosts", "false"));

@davecramer

This comment has been minimized.

Member

davecramer commented Aug 8, 2017

can we close this ?

@vlsi

This comment has been minimized.

Member

vlsi commented Aug 8, 2017

I think text references should be replaced with PgProperty references for cleaner "find usages"

@davecramer

This comment has been minimized.

Member

davecramer commented Aug 8, 2017

Yes, agreed.

@zemian

This comment has been minimized.

Contributor

zemian commented Aug 9, 2017

That looks like easy fix. I can try to help out if you like. :)

@zemian

This comment has been minimized.

Contributor

zemian commented Aug 9, 2017

I also see text ref in ConnectionFactoryImpl#openConnectionImpl() as well:

HostRequirement.valueOf(info.getProperty("targetServerType", HostRequirement.any.name()));

zemian added a commit to zemian/pgjdbc that referenced this issue Aug 10, 2017

vlsi added a commit that referenced this issue Aug 10, 2017

refactor: use PGProperty enum instead of text ref for targetServerTyp…
…e, hostRecheckSeconds, loadBalanceHosts (#912) (#915)

@vlsi vlsi added this to the 42.1.5 milestone Aug 10, 2017

@vlsi vlsi closed this Aug 10, 2017

davecramer added a commit to davecramer/pgjdbc that referenced this issue Sep 19, 2017

@vlsi vlsi modified the milestones: 42.1.5, 42.2.0 Jan 8, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment