|
@@ -543,9 +543,9 @@ public class TestYarnCLI {
|
|
|
PrintWriter pw = new PrintWriter(baos);
|
|
|
pw.println("Total Nodes:1");
|
|
|
pw.print(" Node-Id\t Node-State\tNode-Http-Address\t");
|
|
|
- pw.println("Running-Containers");
|
|
|
- pw.print(" host0:0\t NEW\t host1:8888");
|
|
|
- pw.println("\t 0");
|
|
|
+ pw.println("Number-of-Running-Containers");
|
|
|
+ pw.print(" host0:0\t NEW\t host1:8888\t");
|
|
|
+ pw.println(" 0");
|
|
|
pw.close();
|
|
|
String nodesReportStr = baos.toString("UTF-8");
|
|
|
Assert.assertEquals(nodesReportStr, sysOutStream.toString());
|
|
@@ -564,11 +564,11 @@ public class TestYarnCLI {
|
|
|
pw = new PrintWriter(baos);
|
|
|
pw.println("Total Nodes:2");
|
|
|
pw.print(" Node-Id\t Node-State\tNode-Http-Address\t");
|
|
|
- pw.println("Running-Containers");
|
|
|
- pw.print(" host0:0\t RUNNING\t host1:8888");
|
|
|
- pw.println("\t 0");
|
|
|
- pw.print(" host1:0\t RUNNING\t host1:8888");
|
|
|
- pw.println("\t 0");
|
|
|
+ pw.println("Number-of-Running-Containers");
|
|
|
+ pw.print(" host0:0\t RUNNING\t host1:8888\t");
|
|
|
+ pw.println(" 0");
|
|
|
+ pw.print(" host1:0\t RUNNING\t host1:8888\t");
|
|
|
+ pw.println(" 0");
|
|
|
pw.close();
|
|
|
nodesReportStr = baos.toString("UTF-8");
|
|
|
Assert.assertEquals(nodesReportStr, sysOutStream.toString());
|
|
@@ -593,9 +593,9 @@ public class TestYarnCLI {
|
|
|
pw = new PrintWriter(baos);
|
|
|
pw.println("Total Nodes:1");
|
|
|
pw.print(" Node-Id\t Node-State\tNode-Http-Address\t");
|
|
|
- pw.println("Running-Containers");
|
|
|
- pw.print(" host0:0\t UNHEALTHY\t host1:8888");
|
|
|
- pw.println("\t 0");
|
|
|
+ pw.println("Number-of-Running-Containers");
|
|
|
+ pw.print(" host0:0\t UNHEALTHY\t host1:8888\t");
|
|
|
+ pw.println(" 0");
|
|
|
pw.close();
|
|
|
nodesReportStr = baos.toString("UTF-8");
|
|
|
Assert.assertEquals(nodesReportStr, sysOutStream.toString());
|
|
@@ -614,9 +614,9 @@ public class TestYarnCLI {
|
|
|
pw = new PrintWriter(baos);
|
|
|
pw.println("Total Nodes:1");
|
|
|
pw.print(" Node-Id\t Node-State\tNode-Http-Address\t");
|
|
|
- pw.println("Running-Containers");
|
|
|
- pw.print(" host0:0\t DECOMMISSIONED\t host1:8888");
|
|
|
- pw.println("\t 0");
|
|
|
+ pw.println("Number-of-Running-Containers");
|
|
|
+ pw.print(" host0:0\t DECOMMISSIONED\t host1:8888\t");
|
|
|
+ pw.println(" 0");
|
|
|
pw.close();
|
|
|
nodesReportStr = baos.toString("UTF-8");
|
|
|
Assert.assertEquals(nodesReportStr, sysOutStream.toString());
|
|
@@ -635,9 +635,9 @@ public class TestYarnCLI {
|
|
|
pw = new PrintWriter(baos);
|
|
|
pw.println("Total Nodes:1");
|
|
|
pw.print(" Node-Id\t Node-State\tNode-Http-Address\t");
|
|
|
- pw.println("Running-Containers");
|
|
|
- pw.print(" host0:0\t REBOOTED\t host1:8888");
|
|
|
- pw.println("\t 0");
|
|
|
+ pw.println("Number-of-Running-Containers");
|
|
|
+ pw.print(" host0:0\t REBOOTED\t host1:8888\t");
|
|
|
+ pw.println(" 0");
|
|
|
pw.close();
|
|
|
nodesReportStr = baos.toString("UTF-8");
|
|
|
Assert.assertEquals(nodesReportStr, sysOutStream.toString());
|
|
@@ -656,9 +656,9 @@ public class TestYarnCLI {
|
|
|
pw = new PrintWriter(baos);
|
|
|
pw.println("Total Nodes:1");
|
|
|
pw.print(" Node-Id\t Node-State\tNode-Http-Address\t");
|
|
|
- pw.println("Running-Containers");
|
|
|
- pw.print(" host0:0\t LOST\t host1:8888");
|
|
|
- pw.println("\t 0");
|
|
|
+ pw.println("Number-of-Running-Containers");
|
|
|
+ pw.print(" host0:0\t LOST\t host1:8888\t");
|
|
|
+ pw.println(" 0");
|
|
|
pw.close();
|
|
|
nodesReportStr = baos.toString("UTF-8");
|
|
|
Assert.assertEquals(nodesReportStr, sysOutStream.toString());
|
|
@@ -681,17 +681,17 @@ public class TestYarnCLI {
|
|
|
pw = new PrintWriter(baos);
|
|
|
pw.println("Total Nodes:5");
|
|
|
pw.print(" Node-Id\t Node-State\tNode-Http-Address\t");
|
|
|
- pw.println("Running-Containers");
|
|
|
- pw.print(" host0:0\t NEW\t host1:8888");
|
|
|
- pw.println("\t 0");
|
|
|
- pw.print(" host0:0\t RUNNING\t host1:8888");
|
|
|
- pw.println("\t 0");
|
|
|
- pw.print(" host1:0\t RUNNING\t host1:8888");
|
|
|
- pw.println("\t 0");
|
|
|
- pw.print(" host0:0\t REBOOTED\t host1:8888");
|
|
|
- pw.println("\t 0");
|
|
|
- pw.print(" host0:0\t LOST\t host1:8888");
|
|
|
- pw.println("\t 0");
|
|
|
+ pw.println("Number-of-Running-Containers");
|
|
|
+ pw.print(" host0:0\t NEW\t host1:8888\t");
|
|
|
+ pw.println(" 0");
|
|
|
+ pw.print(" host0:0\t RUNNING\t host1:8888\t");
|
|
|
+ pw.println(" 0");
|
|
|
+ pw.print(" host1:0\t RUNNING\t host1:8888\t");
|
|
|
+ pw.println(" 0");
|
|
|
+ pw.print(" host0:0\t REBOOTED\t host1:8888\t");
|
|
|
+ pw.println(" 0");
|
|
|
+ pw.print(" host0:0\t LOST\t host1:8888\t");
|
|
|
+ pw.println(" 0");
|
|
|
pw.close();
|
|
|
nodesReportStr = baos.toString("UTF-8");
|
|
|
Assert.assertEquals(nodesReportStr, sysOutStream.toString());
|
|
@@ -712,21 +712,21 @@ public class TestYarnCLI {
|
|
|
pw = new PrintWriter(baos);
|
|
|
pw.println("Total Nodes:7");
|
|
|
pw.print(" Node-Id\t Node-State\tNode-Http-Address\t");
|
|
|
- pw.println("Running-Containers");
|
|
|
- pw.print(" host0:0\t NEW\t host1:8888");
|
|
|
- pw.println("\t 0");
|
|
|
- pw.print(" host0:0\t RUNNING\t host1:8888");
|
|
|
- pw.println("\t 0");
|
|
|
- pw.print(" host1:0\t RUNNING\t host1:8888");
|
|
|
- pw.println("\t 0");
|
|
|
- pw.print(" host0:0\t UNHEALTHY\t host1:8888");
|
|
|
- pw.println("\t 0");
|
|
|
- pw.print(" host0:0\t DECOMMISSIONED\t host1:8888");
|
|
|
- pw.println("\t 0");
|
|
|
- pw.print(" host0:0\t REBOOTED\t host1:8888");
|
|
|
- pw.println("\t 0");
|
|
|
- pw.print(" host0:0\t LOST\t host1:8888");
|
|
|
- pw.println("\t 0");
|
|
|
+ pw.println("Number-of-Running-Containers");
|
|
|
+ pw.print(" host0:0\t NEW\t host1:8888\t");
|
|
|
+ pw.println(" 0");
|
|
|
+ pw.print(" host0:0\t RUNNING\t host1:8888\t");
|
|
|
+ pw.println(" 0");
|
|
|
+ pw.print(" host1:0\t RUNNING\t host1:8888\t");
|
|
|
+ pw.println(" 0");
|
|
|
+ pw.print(" host0:0\t UNHEALTHY\t host1:8888\t");
|
|
|
+ pw.println(" 0");
|
|
|
+ pw.print(" host0:0\t DECOMMISSIONED\t host1:8888\t");
|
|
|
+ pw.println(" 0");
|
|
|
+ pw.print(" host0:0\t REBOOTED\t host1:8888\t");
|
|
|
+ pw.println(" 0");
|
|
|
+ pw.print(" host0:0\t LOST\t host1:8888\t");
|
|
|
+ pw.println(" 0");
|
|
|
pw.close();
|
|
|
nodesReportStr = baos.toString("UTF-8");
|
|
|
Assert.assertEquals(nodesReportStr, sysOutStream.toString());
|