Repository: tez Updated Branches: refs/heads/branch-0.7 3e7f9c2ba -> 39fb968c5
TEZ-2792. addendum fix build failure for java 6 (sree) Project: http://git-wip-us.apache.org/repos/asf/tez/repo Commit: http://git-wip-us.apache.org/repos/asf/tez/commit/39fb968c Tree: http://git-wip-us.apache.org/repos/asf/tez/tree/39fb968c Diff: http://git-wip-us.apache.org/repos/asf/tez/diff/39fb968c Branch: refs/heads/branch-0.7 Commit: 39fb968c5279bb9e8959a7309cd8a12694abee03 Parents: 3e7f9c2 Author: Sreenath Somarajapuram <s...@apache.org> Authored: Fri Sep 11 23:47:48 2015 +0530 Committer: Sreenath Somarajapuram <s...@apache.org> Committed: Fri Sep 11 23:47:48 2015 +0530 ---------------------------------------------------------------------- CHANGES.txt | 1 + .../apache/tez/dag/app/web/AMWebController.java | 18 +++++++++--------- 2 files changed, 10 insertions(+), 9 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/tez/blob/39fb968c/CHANGES.txt ---------------------------------------------------------------------- diff --git a/CHANGES.txt b/CHANGES.txt index d8d935d..f842f7d 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -6,6 +6,7 @@ Release 0.7.1: Unreleased INCOMPATIBLE CHANGES ALL CHANGES: + TEZ-2792. addendum fix build failure for java 6 TEZ-2792. Add AM web service API for tasks TEZ-2807. Log data in the finish event instead of the start event TEZ-2789. Backport events added in TEZ-2612 to branch-0.7 http://git-wip-us.apache.org/repos/asf/tez/blob/39fb968c/tez-dag/src/main/java/org/apache/tez/dag/app/web/AMWebController.java ---------------------------------------------------------------------- diff --git a/tez-dag/src/main/java/org/apache/tez/dag/app/web/AMWebController.java b/tez-dag/src/main/java/org/apache/tez/dag/app/web/AMWebController.java index e6ba937..c1ddb28 100644 --- a/tez-dag/src/main/java/org/apache/tez/dag/app/web/AMWebController.java +++ b/tez-dag/src/main/java/org/apache/tez/dag/app/web/AMWebController.java @@ -363,7 +363,7 @@ public class AMWebController extends Controller { } List<String> splitString(String str, String delimiter, Integer limit) { - List<String> items = new ArrayList<>(); + List<String> items = new ArrayList<String>(); StringTokenizer tokenizer = new StringTokenizer(str, delimiter); for(int count = 0; tokenizer.hasMoreElements() && count < limit; count ++) { @@ -386,7 +386,7 @@ public class AMWebController extends Controller { List<Integer> getIntegersFromRequest(String paramName, Integer limit) { String valuesStr = $(paramName).trim(); - List<Integer> values = new ArrayList<>(); + List<Integer> values = new ArrayList<Integer>(); if (!valuesStr.equals("")) { try { for (String valueStr : splitString(valuesStr, ",", limit)) { @@ -418,11 +418,11 @@ public class AMWebController extends Controller { List<List<Integer>> getIDsFromRequest(String paramName, Integer limit) { String valuesStr = $(paramName).trim(); - List<List<Integer>> values = new ArrayList<>(); + List<List<Integer>> values = new ArrayList<List<Integer>>(); if (!valuesStr.equals("")) { try { for (String valueStr : splitString(valuesStr, ",", limit)) { - List<Integer> innerValues = new ArrayList<>(); + List<Integer> innerValues = new ArrayList<Integer>(); String innerValueStrs[] = valueStr.split("_"); if(innerValueStrs.length == 2) { for (String innerValueStr : innerValueStrs) { @@ -528,7 +528,7 @@ public class AMWebController extends Controller { * @param limit {Integer} */ List<Task> getRequestedTasks(DAG dag, Integer limit) { - List<Task> tasks = new ArrayList<>(); + List<Task> tasks = new ArrayList<Task>(); List<List<Integer>> taskIDs = getIDsFromRequest(WebUIService.TASK_ID, limit); if(taskIDs == null) { @@ -564,7 +564,7 @@ public class AMWebController extends Controller { if(vertex == null) { continue; } - List<Task> vertexTasks = new ArrayList<>(vertex.getTasks().values()); + List<Task> vertexTasks = new ArrayList<Task>(vertex.getTasks().values()); tasks.addAll(vertexTasks.subList(0, Math.min(vertexTasks.size(), limit - tasks.size()))); if(tasks.size() >= limit) { @@ -575,7 +575,7 @@ public class AMWebController extends Controller { else { Collection<Vertex> vertices = dag.getVertices().values(); for (Vertex vertex : vertices) { - List<Task> vertexTasks = new ArrayList<>(vertex.getTasks().values()); + List<Task> vertexTasks = new ArrayList<Task>(vertex.getTasks().values()); tasks.addAll(vertexTasks.subList(0, Math.min(vertexTasks.size(), limit - tasks.size()))); if(tasks.size() >= limit) { @@ -614,9 +614,9 @@ public class AMWebController extends Controller { return; } - ArrayList<Map<String, String>> tasksInfo = new ArrayList<>(); + ArrayList<Map<String, String>> tasksInfo = new ArrayList<Map<String, String>>(); for(Task t : tasks) { - Map<String, String> taskInfo = new HashMap<>(); + Map<String, String> taskInfo = new HashMap<String, String>(); taskInfo.put("id", t.getTaskId().toString()); taskInfo.put("progress", Float.toString(t.getProgress())); taskInfo.put("status", t.getState().toString());