Skip to content

introduce offer cache to allow better resource allocation - #1402

Merged
ssalinas merged 19 commits into
masterfrom
offer_cache
Mar 10, 2017
Merged

ssalinas merged 19 commits into
masterfrom
offer_cache

Conversation

@wsorenson

@wsorenson wsorenson commented Jan 19, 2017 •

Copy link
Copy Markdown
Contributor

Currently, does not use cached offers.

@ssalinas ssalinas modified the milestone: 0.14.0 Jan 20, 2017

private void checkOut() {
LOG.trace("Checking out offer {}", offerId);
Preconditions.checkState(offerState == OfferState.AVAILABLE, "Offer %s was in state %s", offerId, offerState);

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Saw a sentry come through for this the other day. This exception will bubble all the way back up to the LeaderOnlyPoller and cause us to abort. Should we maybe catch this and just skip the offer in the case that something else has it checked out?


public void returnOffer(CachedOffer cachedOffer);

public List<Offer> peakOffers();

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

peekOffers()?

@ssalinas

Copy link
Copy Markdown
Contributor

Fixed the merge conflicts and re-tested in each environment as well, going to merge this one 👍

@ssalinas
ssalinas merged commit 118c4e9 into master Mar 10, 2017
@miry

miry commented May 8, 2017 •

Copy link
Copy Markdown

@wsorenson how to disable this this feature?

I could not find related info in http://getsingularity.com/Docs/reference/configuration.html.

I think this feature eats all Mesos resources and then free some of them in 1 minute, and then again takes. So other frameworks could not run job fast.

@tpetr

tpetr commented May 8, 2017

Copy link
Copy Markdown
Contributor

@miry It looks like the documentation needs to be updated, thanks for the heads up. You can disable offer caching by setting cacheOffers: false in your Singularity config YAML.

@ssalinas @wsorenson thoughts on having offer caching disabled by default?

@ssalinas

ssalinas commented May 8, 2017

Copy link
Copy Markdown
Contributor

For the sake of those running in multi-framework clusters it might make sense to have it off by default. I can submit a PR with that and the documentation update

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.

5 participants