Skip to content
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

[Backport][ipa-4-5] Sort and shuffle SRV record by priority and weight #2041

Closed
wants to merge 1 commit into from

Conversation

tiran
Copy link
Member

@tiran tiran commented Jun 19, 2018

On multiple occasions, SRV query answers were not properly sorted by
priority. Records with same priority weren't randomized and shuffled.
This caused FreeIPA to contact the same remote peer instead of
distributing the load across all available servers.

Two new helper functions now take care of SRV queries. sort_prio_weight()
sorts SRV and URI records. query_srv() combines SRV lookup with
sort_prio_weight().

PR was ACKed manually because this is backport of PR #2032.

Fixes: https://pagure.io/freeipa/issue/7475
Signed-off-by: Christian Heimes cheimes@redhat.com
Reviewed-By: Rob Crittenden rcritten@redhat.com

On multiple occasions, SRV query answers were not properly sorted by
priority. Records with same priority weren't randomized and shuffled.
This caused FreeIPA to contact the same remote peer instead of
distributing the load across all available servers.

Two new helper functions now take care of SRV queries. sort_prio_weight()
sorts SRV and URI records. query_srv() combines SRV lookup with
sort_prio_weight().

Fixes: https://pagure.io/freeipa/issue/7475
Signed-off-by: Christian Heimes <cheimes@redhat.com>
Reviewed-By: Rob Crittenden <rcritten@redhat.com>
@tiran tiran added the ack Pull Request approved, can be merged label Jun 19, 2018
@Tiboris Tiboris added the pushed Pull Request has already been pushed label Jun 19, 2018
@Tiboris
Copy link
Member

Tiboris commented Jun 19, 2018

ipa-4-5:

  • 76fb775 Sort and shuffle SRV record by priority and weight

@Tiboris Tiboris closed this Jun 19, 2018
@tiran tiran deleted the backport_2032_ipa-4-5 branch June 19, 2018 10:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ack Pull Request approved, can be merged pushed Pull Request has already been pushed
Projects
None yet
2 participants