当前位置: 首页>>代码示例>>Java>>正文


Java Protos.ExecutorID方法代码示例

本文整理汇总了Java中org.apache.mesos.Protos.ExecutorID方法的典型用法代码示例。如果您正苦于以下问题:Java Protos.ExecutorID方法的具体用法?Java Protos.ExecutorID怎么用?Java Protos.ExecutorID使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在org.apache.mesos.Protos的用法示例。


在下文中一共展示了Protos.ExecutorID方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: testToExecutorId

import org.apache.mesos.Protos; //导入方法依赖的package包/类
@Test
public void testToExecutorId() {
    final String executorName = "dcos-0";

    final Protos.ExecutorID executorID = CommonIdUtils.toExecutorId(executorName);

    Assert.assertNotNull(executorID);
    final String value = executorID.getValue();
    Assert.assertTrue(StringUtils.isNotBlank(value));
    Assert.assertTrue(value.contains("__"));
    Assert.assertNotNull(UUID.fromString(value.split("__")[1]));
}
 
开发者ID:mesosphere,项目名称:dcos-commons,代码行数:13,代码来源:CommonIdUtilsTest.java

示例2: frameworkMessage

import org.apache.mesos.Protos; //导入方法依赖的package包/类
@Override
public void frameworkMessage(SchedulerDriver driver,
                             Protos.ExecutorID executorId,
                             Protos.SlaveID slaveId,
                             byte[] data) {
    LOGGER.info("Framework message: executorId={} slaveId={} data='{}'",
            executorId.getValue(), slaveId.getValue(),
            Arrays.toString(data));
}
 
开发者ID:mesosphere,项目名称:dcos-cassandra-service,代码行数:10,代码来源:CassandraScheduler.java

示例3: executorLost

import org.apache.mesos.Protos; //导入方法依赖的package包/类
@Override
public void executorLost(SchedulerDriver driver,
                         Protos.ExecutorID executorId,
                         Protos.SlaveID slaveId,
                         int status) {
    LOGGER.info("Executor lost: executorId: {} slaveId: {} status: {}",
            executorId.getValue(), slaveId.getValue(), status);
}
 
开发者ID:mesosphere,项目名称:dcos-cassandra-service,代码行数:9,代码来源:CassandraScheduler.java

示例4: isRunningExecutor

import org.apache.mesos.Protos; //导入方法依赖的package包/类
private static boolean isRunningExecutor(Protos.ExecutorInfo executorInfo, Protos.Offer offer) {
    for (Protos.ExecutorID execId : offer.getExecutorIdsList()) {
        if (execId.equals(executorInfo.getExecutorId())) {
            return true;
        }
    }

    return false;
}
 
开发者ID:mesosphere,项目名称:dcos-commons,代码行数:10,代码来源:VolumeEvaluationStage.java

示例5: sendStatusUpdate

import org.apache.mesos.Protos; //导入方法依赖的package包/类
private void sendStatusUpdate(ExecutorDriver executorDriver, Protos.TaskState state, Protos.TaskID taskId, Protos.ExecutorID executorId) {
    Protos.TaskStatus taskStatus = Protos.TaskStatus.newBuilder()
            .setExecutorId(executorId)
            .setTaskId(taskId)
            .setState(state)
            .setSource(Protos.TaskStatus.Source.SOURCE_EXECUTOR)
            .build();
    executorDriver.sendStatusUpdate(taskStatus);
}
 
开发者ID:hazelcast,项目名称:hazelcast-mesos,代码行数:10,代码来源:HazelcastExecutor.java

示例6: getCompleteOffer

import org.apache.mesos.Protos; //导入方法依赖的package包/类
public static Protos.Offer getCompleteOffer(Protos.ExecutorID executorId, List<Protos.Resource> resources) {
    Protos.Offer.Builder builder = getEmptyOfferBuilder();
    builder.addAllResources(resources);

    if (executorId != null) {
        builder.addExecutorIds(executorId);
    }

    return builder.build();
}
 
开发者ID:mesosphere,项目名称:dcos-commons,代码行数:11,代码来源:OfferTestUtils.java

示例7: frameworkMessage

import org.apache.mesos.Protos; //导入方法依赖的package包/类
@Override
public void frameworkMessage(final SchedulerDriver schedulerDriver, final Protos.ExecutorID executorID, final Protos.SlaveID slaveID, final byte[] bytes) {
    log.trace("call frameworkMessage slaveID: {}, bytes: {}", slaveID, new String(bytes));
}
 
开发者ID:elasticjob,项目名称:elastic-job-cloud,代码行数:5,代码来源:SchedulerEngine.java

示例8: executorLost

import org.apache.mesos.Protos; //导入方法依赖的package包/类
@Override
public void executorLost(final SchedulerDriver schedulerDriver, final Protos.ExecutorID executorID, final Protos.SlaveID slaveID, final int i) {
    log.warn("call executorLost slaveID is: {}, executorID is: {}", slaveID, executorID);
}
 
开发者ID:elasticjob,项目名称:elastic-job-cloud,代码行数:5,代码来源:SchedulerEngine.java

示例9: sendFrameworkMessage

import org.apache.mesos.Protos; //导入方法依赖的package包/类
public Protos.Status sendFrameworkMessage(Protos.ExecutorID executorId, Protos.SlaveID slaveId, byte[] data) {
    sentFrameworkMessages.add(new Message(executorId.getValue(), slaveId.getValue(), data));
    return status;
}
 
开发者ID:elodina,项目名称:java-mesos-util,代码行数:5,代码来源:TestSchedulerDriver.java

示例10: executorId

import org.apache.mesos.Protos; //导入方法依赖的package包/类
public Protos.ExecutorID executorId() {
	return executorId;
}
 
开发者ID:axbaretto,项目名称:flink,代码行数:4,代码来源:FrameworkMessage.java

示例11: FrameworkMessage

import org.apache.mesos.Protos; //导入方法依赖的package包/类
public FrameworkMessage(Protos.ExecutorID executorId, Protos.SlaveID slaveId, byte[] data) {
	this.executorId = executorId;
	this.slaveId = slaveId;
	this.data = data;
}
 
开发者ID:axbaretto,项目名称:flink,代码行数:6,代码来源:FrameworkMessage.java

示例12: executorLost

import org.apache.mesos.Protos; //导入方法依赖的package包/类
@Override
public void executorLost(SchedulerDriver schedulerDriver, Protos.ExecutorID executorID, Protos.SlaveID slaveID, int i) {
  logger.info("executorLost()");
}
 
开发者ID:yanglei99,项目名称:Mesos_Auto_Scale,代码行数:5,代码来源:FenzoScheduler.java

示例13: ExecutorLost

import org.apache.mesos.Protos; //导入方法依赖的package包/类
public ExecutorLost(Protos.ExecutorID executorId, Protos.SlaveID slaveId, int status) {
	this.executorId = executorId;
	this.slaveId = slaveId;
	this.status = status;
}
 
开发者ID:axbaretto,项目名称:flink,代码行数:6,代码来源:ExecutorLost.java

示例14: sendFrameworkMessage

import org.apache.mesos.Protos; //导入方法依赖的package包/类
public Protos.Status sendFrameworkMessage(Protos.ExecutorID executorID,
                                          Protos.SlaveID slaveID,
                                          byte[] data) {
    return Protos.Status.DRIVER_RUNNING;
}
 
开发者ID:retz,项目名称:retz,代码行数:6,代码来源:LocalSchedulerDriver.java

示例15: executorLost

import org.apache.mesos.Protos; //导入方法依赖的package包/类
@Override
public void executorLost(SchedulerDriver driver, Protos.ExecutorID executorId, Protos.SlaveID slaveId, int status) {
    logger.debug("[executorLost] executor" + json(executorId) + ", slave:" + json(slaveId) + ", status:" + status);
}
 
开发者ID:elodina,项目名称:java-mesos-util,代码行数:5,代码来源:SchedulerDriverV0.java


注:本文中的org.apache.mesos.Protos.ExecutorID方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。