|
@@ -1305,6 +1305,8 @@ public class TestRMWebServicesApps extends JerseyTestBase {
|
|
WebServicesTestUtils.getXmlInt(element, "allocatedMB"),
|
|
WebServicesTestUtils.getXmlInt(element, "allocatedMB"),
|
|
WebServicesTestUtils.getXmlInt(element, "allocatedVCores"),
|
|
WebServicesTestUtils.getXmlInt(element, "allocatedVCores"),
|
|
WebServicesTestUtils.getXmlInt(element, "runningContainers"),
|
|
WebServicesTestUtils.getXmlInt(element, "runningContainers"),
|
|
|
|
+ WebServicesTestUtils.getXmlFloat(element, "queueUsagePercentage"),
|
|
|
|
+ WebServicesTestUtils.getXmlFloat(element, "clusterUsagePercentage"),
|
|
WebServicesTestUtils.getXmlInt(element, "preemptedResourceMB"),
|
|
WebServicesTestUtils.getXmlInt(element, "preemptedResourceMB"),
|
|
WebServicesTestUtils.getXmlInt(element, "preemptedResourceVCores"),
|
|
WebServicesTestUtils.getXmlInt(element, "preemptedResourceVCores"),
|
|
WebServicesTestUtils.getXmlInt(element, "numNonAMContainerPreempted"),
|
|
WebServicesTestUtils.getXmlInt(element, "numNonAMContainerPreempted"),
|
|
@@ -1319,7 +1321,7 @@ public class TestRMWebServicesApps extends JerseyTestBase {
|
|
public void verifyAppInfo(JSONObject info, RMApp app) throws JSONException,
|
|
public void verifyAppInfo(JSONObject info, RMApp app) throws JSONException,
|
|
Exception {
|
|
Exception {
|
|
|
|
|
|
- int expectedNumberOfElements = 30;
|
|
|
|
|
|
+ int expectedNumberOfElements = 32;
|
|
String appNodeLabelExpression = null;
|
|
String appNodeLabelExpression = null;
|
|
String amNodeLabelExpression = null;
|
|
String amNodeLabelExpression = null;
|
|
if (app.getApplicationSubmissionContext()
|
|
if (app.getApplicationSubmissionContext()
|
|
@@ -1344,6 +1346,8 @@ public class TestRMWebServicesApps extends JerseyTestBase {
|
|
info.getLong("elapsedTime"), info.getString("amHostHttpAddress"),
|
|
info.getLong("elapsedTime"), info.getString("amHostHttpAddress"),
|
|
info.getString("amContainerLogs"), info.getInt("allocatedMB"),
|
|
info.getString("amContainerLogs"), info.getInt("allocatedMB"),
|
|
info.getInt("allocatedVCores"), info.getInt("runningContainers"),
|
|
info.getInt("allocatedVCores"), info.getInt("runningContainers"),
|
|
|
|
+ (float) info.getDouble("queueUsagePercentage"),
|
|
|
|
+ (float) info.getDouble("clusterUsagePercentage"),
|
|
info.getInt("preemptedResourceMB"),
|
|
info.getInt("preemptedResourceMB"),
|
|
info.getInt("preemptedResourceVCores"),
|
|
info.getInt("preemptedResourceVCores"),
|
|
info.getInt("numNonAMContainerPreempted"),
|
|
info.getInt("numNonAMContainerPreempted"),
|
|
@@ -1360,6 +1364,7 @@ public class TestRMWebServicesApps extends JerseyTestBase {
|
|
String diagnostics, long clusterId, long startedTime, long finishedTime,
|
|
String diagnostics, long clusterId, long startedTime, long finishedTime,
|
|
long elapsedTime, String amHostHttpAddress, String amContainerLogs,
|
|
long elapsedTime, String amHostHttpAddress, String amContainerLogs,
|
|
int allocatedMB, int allocatedVCores, int numContainers,
|
|
int allocatedMB, int allocatedVCores, int numContainers,
|
|
|
|
+ float queueUsagePerc, float clusterUsagePerc,
|
|
int preemptedResourceMB, int preemptedResourceVCores,
|
|
int preemptedResourceMB, int preemptedResourceVCores,
|
|
int numNonAMContainerPreempted, int numAMContainerPreempted,
|
|
int numNonAMContainerPreempted, int numAMContainerPreempted,
|
|
String logAggregationStatus, boolean unmanagedApplication,
|
|
String logAggregationStatus, boolean unmanagedApplication,
|
|
@@ -1399,6 +1404,8 @@ public class TestRMWebServicesApps extends JerseyTestBase {
|
|
amContainerLogs.endsWith("/" + app.getUser()));
|
|
amContainerLogs.endsWith("/" + app.getUser()));
|
|
assertEquals("allocatedMB doesn't match", 1024, allocatedMB);
|
|
assertEquals("allocatedMB doesn't match", 1024, allocatedMB);
|
|
assertEquals("allocatedVCores doesn't match", 1, allocatedVCores);
|
|
assertEquals("allocatedVCores doesn't match", 1, allocatedVCores);
|
|
|
|
+ assertEquals("queueUsagePerc doesn't match", 50.0f, queueUsagePerc, 0.01f);
|
|
|
|
+ assertEquals("clusterUsagePerc doesn't match", 50.0f, clusterUsagePerc, 0.01f);
|
|
assertEquals("numContainers doesn't match", 1, numContainers);
|
|
assertEquals("numContainers doesn't match", 1, numContainers);
|
|
assertEquals("preemptedResourceMB doesn't match", app
|
|
assertEquals("preemptedResourceMB doesn't match", app
|
|
.getRMAppMetrics().getResourcePreempted().getMemory(),
|
|
.getRMAppMetrics().getResourcePreempted().getMemory(),
|