use of org.apache.mesos.v1.scheduler.Protos.Call.Type in project Singularity by HubSpot.
the class SingularityMesosSchedulerClient method accept.
/**
* Sent by the scheduler when it accepts offer(s) sent by the master. The ACCEPT request includes the type of
* operations (e.g., launch task, launch task group, reserve resources, create volumes) that the scheduler wants to
* perform on the offers. Note that until the scheduler replies (accepts or declines) to an offer, the offer’s
* resources are considered allocated to the offer’s role and to the framework.
*
* @param offerIds
* @param offerOperations
*/
public void accept(List<OfferID> offerIds, List<Offer.Operation> offerOperations) {
Builder accept = build().setAccept(Accept.newBuilder().addAllOfferIds(offerIds).addAllOperations(offerOperations));
sendCall(accept, Type.ACCEPT);
}
use of org.apache.mesos.v1.scheduler.Protos.Call.Type in project Singularity by HubSpot.
the class SingularityMesosSchedulerClient method sendCall.
private void sendCall(Call.Builder b, Type t) {
Call call = b.setType(t).setFrameworkId(frameworkId).build();
sendCall(call);
}
Aggregations