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

Take system usage into account when scoring offers #1711

Merged
merged 7 commits into from
Feb 15, 2018
Merged

Conversation

ssalinas
Copy link
Member

  • Also collect system usage for mesos slaves
  • Ability to score on system vs task usage on the slave
  • fix a missing lock in drainPendingQueue
  • fix bug in grabbing slave usage by id

case SPREAD_SYSTEM_USAGE:
default:
double systemCpuFreeScore = Math.max(0, 1 - slaveUsage.getSystemLoad15Min());
double systemMemFreeScore = 1 - (slaveUsage.getSystemMemTotalBytes() - slaveUsage.getSystemMemTotalBytes()) / slaveUsage.getSystemMemTotalBytes();
Copy link
Contributor

Choose a reason for hiding this comment

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

I think this should be slaveUsage.getSystemMemTotalBytes() - slaveUsage.getSystemMemFreeBytes()

Copy link
Member Author

Choose a reason for hiding this comment

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

thanks, fixed

@ssalinas ssalinas added the hs_qa label Feb 15, 2018
@ssalinas ssalinas added this to the 0.19.0 milestone Feb 15, 2018
@matush-v
Copy link
Contributor

lgtm 🚢

@ssalinas ssalinas merged commit 500c283 into master Feb 15, 2018
@ssalinas ssalinas deleted the rebalance branch February 15, 2018 17:14
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.

2 participants