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

add intelligent windows tolerations based on node taints #609

Merged
merged 1 commit into from
Jan 27, 2021

Conversation

tomkennedy513
Copy link
Collaborator

  • we only do this if the taints across all windows nodes are homogenous

@tomkennedy513 tomkennedy513 force-pushed the intelligent-windows-tolerations branch 3 times, most recently from 53415a6 to c3714a9 Compare January 26, 2021 22:30
@tomkennedy513 tomkennedy513 marked this pull request as ready for review January 26, 2021 22:43
@tomkennedy513 tomkennedy513 linked an issue Jan 26, 2021 that may be closed by this pull request
@tylerphelan
Copy link
Contributor

should we do a provider pattern?

Comment on lines +198 to +204
sort.Slice(taintsToCompare, func(i, j int) bool {
return taintsToCompare[i].Key < taintsToCompare[j].Key
})
Copy link

@aemengo aemengo Jan 27, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As an optimization, maybe we can move this second sort to be inside the func taintsEqual(, after the size check.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i had that originally, but i changed it because even though its slightly less performant, i felt like it was a little weird to be sorting in the equals function, especially since i was only sorting one slice

@aemengo aemengo self-requested a review January 27, 2021 20:02
- we only do this if the taints across all windows nodes are homogenous
@tomkennedy513 tomkennedy513 merged commit 245f680 into master Jan 27, 2021
@tomkennedy513 tomkennedy513 deleted the intelligent-windows-tolerations branch January 27, 2021 20:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Intelligently apply tolerations to windows pods
4 participants