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

Bounce deny #766

Merged
merged 5 commits into from
Dec 4, 2015
Merged

Bounce deny #766

merged 5 commits into from
Dec 4, 2015

Conversation

ssalinas
Copy link
Member

For OPTIMISTIC and GREEDY it shouldn't matter. But, if placement is SEPARATE*, don't allow us to start a bounce we know we can't complete

if (placement != SlavePlacement.GREEDY && placement != SlavePlacement.OPTIMISTIC) {
int currentActiveSlaveCount = slaveManager.getNumObjectsAtState(MachineState.ACTIVE);
int requiredSlaveCount = requestWithState.getRequest().getInstancesSafe() * 2;
checkBadRequest(currentActiveSlaveCount >= requiredSlaveCount, "Not enough slaves to successfully complete a bounce of reqeust %s (minimum required: %s, current: %s)", requestId, requiredSlaveCount, currentActiveSlaveCount);
Copy link
Contributor

Choose a reason for hiding this comment

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

can you clarify this to Not enough active slaves... and maybe include guidance to consider deploying instead of bouncing or changing the slave placement?

if (placement != SlavePlacement.GREEDY && placement != SlavePlacement.OPTIMISTIC) {
int currentActiveSlaveCount = slaveManager.getNumObjectsAtState(MachineState.ACTIVE);
int requiredSlaveCount = requestWithState.getRequest().getInstancesSafe() * 2;
checkBadRequest(currentActiveSlaveCount >= requiredSlaveCount, "Not enough active slaves to successfully complete a bounce of reqeust %s (minimum required: %s, current: %s). Consider deploying or changing the slave placement strategy instead", requestId, requiredSlaveCount, currentActiveSlaveCount);

Choose a reason for hiding this comment

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

request ?

Copy link
Member Author

Choose a reason for hiding this comment

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

whoops, thanks

@tpetr tpetr added the hs_stable label Dec 3, 2015
@tpetr tpetr added this to the 0.4.6 milestone Dec 4, 2015
@tpetr tpetr merged commit 6f43bc3 into master Dec 4, 2015
@tpetr tpetr removed hs_qa labels Dec 4, 2015
@tpetr tpetr deleted the bounce_deny branch December 4, 2015 20:05
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.

3 participants