Search in sources :

Example 16 with Request

use of org.apache.mesos.v1.scheduler.Protos.Call.Request in project Singularity by HubSpot.

the class SingularityMesosSchedulerClient method request.

/**
 * Sent by the scheduler to request resources from the master/allocator. The built-in hierarchical allocator simply
 * ignores this request but other allocators can interpret this in a customizable fashion.
 *
 * @param requests
 */
public void request(List<org.apache.mesos.v1.Protos.Request> requests) {
    Builder request = build().setRequest(Request.newBuilder().addAllRequests(requests));
    sendCall(request, Type.REQUEST);
}
Also used : MesosClientBuilder(com.mesosphere.mesos.rx.java.MesosClientBuilder) ProtobufMesosClientBuilder(com.mesosphere.mesos.rx.java.protobuf.ProtobufMesosClientBuilder) Builder(org.apache.mesos.v1.scheduler.Protos.Call.Builder)

Aggregations

SingularityTaskRequest (com.hubspot.singularity.SingularityTaskRequest)9 Test (org.junit.Test)9 SingularityRequest (com.hubspot.singularity.SingularityRequest)8 SingularityDeployBuilder (com.hubspot.singularity.SingularityDeployBuilder)7 SingularityRequestBuilder (com.hubspot.singularity.SingularityRequestBuilder)7 Resources (com.hubspot.mesos.Resources)6 SingularityDeploy (com.hubspot.singularity.SingularityDeploy)6 SingularityMesosTaskHolder (com.hubspot.singularity.helpers.SingularityMesosTaskHolder)6 SingularityTask (com.hubspot.singularity.SingularityTask)5 SingularityContainerInfo (com.hubspot.mesos.SingularityContainerInfo)4 SingularityDockerPortMapping (com.hubspot.mesos.SingularityDockerPortMapping)4 SingularityTaskId (com.hubspot.singularity.SingularityTaskId)4 Protos (org.apache.mesos.v1.Protos)4 SingularityDockerInfo (com.hubspot.mesos.SingularityDockerInfo)3 SingularityPortMapping (com.hubspot.mesos.SingularityPortMapping)3 SingularityVolume (com.hubspot.mesos.SingularityVolume)3 MesosClientBuilder (com.mesosphere.mesos.rx.java.MesosClientBuilder)3 ProtobufMesosClientBuilder (com.mesosphere.mesos.rx.java.protobuf.ProtobufMesosClientBuilder)3 ArrayList (java.util.ArrayList)3 Optional (com.google.common.base.Optional)2