本文整理汇总了Java中org.apache.hadoop.yarn.server.api.protocolrecords.NMContainerStatus.newInstance方法的典型用法代码示例。如果您正苦于以下问题:Java NMContainerStatus.newInstance方法的具体用法?Java NMContainerStatus.newInstance怎么用?Java NMContainerStatus.newInstance使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类org.apache.hadoop.yarn.server.api.protocolrecords.NMContainerStatus
的用法示例。
在下文中一共展示了NMContainerStatus.newInstance方法的11个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: getNMContainerStatus
import org.apache.hadoop.yarn.server.api.protocolrecords.NMContainerStatus; //导入方法依赖的package包/类
@Override
public NMContainerStatus getNMContainerStatus() {
this.readLock.lock();
try {
return NMContainerStatus.newInstance(this.containerId, getCurrentState(),
getResource(), diagnostics.toString(), exitCode,
containerTokenIdentifier.getPriority(),
containerTokenIdentifier.getCreationTime());
} finally {
this.readLock.unlock();
}
}
示例2: createNMContainerStatus
import org.apache.hadoop.yarn.server.api.protocolrecords.NMContainerStatus; //导入方法依赖的package包/类
public static NMContainerStatus createNMContainerStatus(int id,
ContainerState containerState) {
ApplicationId applicationId = ApplicationId.newInstance(0, 1);
ApplicationAttemptId applicationAttemptId =
ApplicationAttemptId.newInstance(applicationId, 1);
ContainerId containerId = ContainerId.newContainerId(applicationAttemptId, id);
NMContainerStatus containerReport =
NMContainerStatus.newInstance(containerId, containerState,
Resource.newInstance(1024, 1), "recover container", 0,
Priority.newInstance(10), 0);
return containerReport;
}
示例3: createNMContainerStatus
import org.apache.hadoop.yarn.server.api.protocolrecords.NMContainerStatus; //导入方法依赖的package包/类
public static NMContainerStatus createNMContainerStatus(
ApplicationAttemptId appAttemptId, int id, ContainerState containerState) {
ContainerId containerId = ContainerId.newContainerId(appAttemptId, id);
NMContainerStatus containerReport =
NMContainerStatus.newInstance(containerId, containerState,
Resource.newInstance(1024, 1), "recover container", 0,
Priority.newInstance(0), 0);
return containerReport;
}
示例4: createNMContainerStatus
import org.apache.hadoop.yarn.server.api.protocolrecords.NMContainerStatus; //导入方法依赖的package包/类
public static NMContainerStatus createNMContainerStatus(
ApplicationAttemptId appAttemptId, int id, ContainerState containerState,
int memory) {
ContainerId containerId = ContainerId.newContainerId(appAttemptId, id);
NMContainerStatus containerReport =
NMContainerStatus.newInstance(containerId, containerState,
Resource.newInstance(memory, 1, 1), "recover container", 0,
Priority.newInstance(0), 0);
return containerReport;
}
示例5: getNMContainerStatus
import org.apache.hadoop.yarn.server.api.protocolrecords.NMContainerStatus; //导入方法依赖的package包/类
@Override
public NMContainerStatus getNMContainerStatus() {
this.readLock.lock();
try {
return NMContainerStatus.newInstance(this.containerId, getCurrentState(),
getResource(), diagnostics.toString(), exitCode,
containerTokenIdentifier.getPriority(),
containerTokenIdentifier.getCreationTime(),
containerTokenIdentifier.getNodeLabelExpression());
} finally {
this.readLock.unlock();
}
}
示例6: createNMContainerStatus
import org.apache.hadoop.yarn.server.api.protocolrecords.NMContainerStatus; //导入方法依赖的package包/类
public static NMContainerStatus createNMContainerStatus(
ApplicationAttemptId appAttemptId, int id, ContainerState containerState,
String nodeLabelExpression) {
ContainerId containerId = ContainerId.newContainerId(appAttemptId, id);
NMContainerStatus containerReport =
NMContainerStatus.newInstance(containerId, containerState,
Resource.newInstance(1024, 1), "recover container", 0,
Priority.newInstance(0), 0, nodeLabelExpression);
return containerReport;
}
示例7: createNMContainerStatus
import org.apache.hadoop.yarn.server.api.protocolrecords.NMContainerStatus; //导入方法依赖的package包/类
public static NMContainerStatus createNMContainerStatus(
ApplicationAttemptId appAttemptId, int id, ContainerState containerState,
int memory) {
ContainerId containerId = ContainerId.newContainerId(appAttemptId, id);
NMContainerStatus containerReport =
NMContainerStatus.newInstance(containerId, containerState,
Resource.newInstance(memory, 1), "recover container", 0,
Priority.newInstance(0), 0);
return containerReport;
}
示例8: getNMContainerStatus
import org.apache.hadoop.yarn.server.api.protocolrecords.NMContainerStatus; //导入方法依赖的package包/类
@Override
public NMContainerStatus getNMContainerStatus() {
this.readLock.lock();
try {
return NMContainerStatus.newInstance(this.containerId, this.version,
getCurrentState(), getResource(), diagnostics.toString(), exitCode,
containerTokenIdentifier.getPriority(),
containerTokenIdentifier.getCreationTime(),
containerTokenIdentifier.getNodeLabelExpression());
} finally {
this.readLock.unlock();
}
}
示例9: createNMContainerStatus
import org.apache.hadoop.yarn.server.api.protocolrecords.NMContainerStatus; //导入方法依赖的package包/类
public static NMContainerStatus createNMContainerStatus(int id,
ContainerState containerState) {
ApplicationId applicationId = ApplicationId.newInstance(0, 1);
ApplicationAttemptId applicationAttemptId =
ApplicationAttemptId.newInstance(applicationId, 1);
ContainerId containerId = ContainerId.newContainerId(applicationAttemptId, id);
NMContainerStatus containerReport =
NMContainerStatus.newInstance(containerId, 0, containerState,
Resource.newInstance(1024, 1), "recover container", 0,
Priority.newInstance(10), 0);
return containerReport;
}
示例10: createNMContainerStatus
import org.apache.hadoop.yarn.server.api.protocolrecords.NMContainerStatus; //导入方法依赖的package包/类
public static NMContainerStatus createNMContainerStatus(
ApplicationAttemptId appAttemptId, int id, ContainerState containerState,
String nodeLabelExpression) {
ContainerId containerId = ContainerId.newContainerId(appAttemptId, id);
NMContainerStatus containerReport =
NMContainerStatus.newInstance(containerId, 0, containerState,
Resource.newInstance(1024, 1), "recover container", 0,
Priority.newInstance(0), 0, nodeLabelExpression);
return containerReport;
}
示例11: createNMContainerStatus
import org.apache.hadoop.yarn.server.api.protocolrecords.NMContainerStatus; //导入方法依赖的package包/类
public static NMContainerStatus createNMContainerStatus(
ApplicationAttemptId appAttemptId, int id, ContainerState containerState,
int memory) {
ContainerId containerId = ContainerId.newContainerId(appAttemptId, id);
NMContainerStatus containerReport =
NMContainerStatus.newInstance(containerId, 0, containerState,
Resource.newInstance(memory, 1), "recover container", 0,
Priority.newInstance(0), 0);
return containerReport;
}