Browse Source

MAPREDUCE-3913. RM application webpage is unresponsive after 2000 jobs (Jason Lowe via tgraves)

git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/trunk@1294207 13f79535-47bb-0310-9956-ffa450edef68
Thomas Graves 13 years ago
parent
commit
d6170f00b1

+ 3 - 0
hadoop-mapreduce-project/CHANGES.txt

@@ -178,6 +178,9 @@ Release 0.23.2 - UNRELEASED
     MAPREDUCE-3686. Fixed two bugs in Counters because of which web app displays
     MAPREDUCE-3686. Fixed two bugs in Counters because of which web app displays
     zero counter values for framework counters. (Bhallamudi Venkata Siva Kamesh
     zero counter values for framework counters. (Bhallamudi Venkata Siva Kamesh
     via vinodkv)
     via vinodkv)
+
+    MAPREDUCE-3913. RM application webpage is unresponsive after 2000 jobs 
+    (Jason Lowe via tgraves)
  
  
 Release 0.23.1 - 2012-02-17 
 Release 0.23.1 - 2012-02-17 
 
 

+ 0 - 6
hadoop-mapreduce-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-resourcemanager/src/main/java/org/apache/hadoop/yarn/server/resourcemanager/webapp/RmView.java

@@ -30,7 +30,6 @@ import static org.apache.hadoop.yarn.webapp.view.JQueryUI.*;
 public class RmView extends TwoColumnLayout {
 public class RmView extends TwoColumnLayout {
   static final int MAX_DISPLAY_ROWS = 100;  // direct table rendering
   static final int MAX_DISPLAY_ROWS = 100;  // direct table rendering
   static final int MAX_FAST_ROWS = 1000;    // inline js array
   static final int MAX_FAST_ROWS = 1000;    // inline js array
-  static final int MAX_INLINE_ROWS = 2000;  // ajax load
 
 
   @Override
   @Override
   protected void preHead(Page.HTML<_> html) {
   protected void preHead(Page.HTML<_> html) {
@@ -81,11 +80,6 @@ public class RmView extends TwoColumnLayout {
     if (list.apps.size() > MAX_FAST_ROWS) {
     if (list.apps.size() > MAX_FAST_ROWS) {
       tableInitProgress(init, list.apps.size() * 6);
       tableInitProgress(init, list.apps.size() * 6);
     }
     }
-    if (list.apps.size() > MAX_INLINE_ROWS) {
-      list.rendering = Render.JS_LOAD;
-      return init.append(", sAjaxSource:'").append(url("apps", "json")).
-          append("'}").toString();
-    }
     list.rendering = Render.JS_ARRAY;
     list.rendering = Render.JS_ARRAY;
     return init.append(", aaData:appsData}").toString();
     return init.append(", aaData:appsData}").toString();
   }
   }

+ 8 - 1
hadoop-mapreduce-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-resourcemanager/src/test/java/org/apache/hadoop/yarn/server/resourcemanager/webapp/TestRMWebApp.java

@@ -177,8 +177,10 @@ public class TestRMWebApp {
   public static ResourceManager mockRm(RMContext rmContext) throws IOException {
   public static ResourceManager mockRm(RMContext rmContext) throws IOException {
     ResourceManager rm = mock(ResourceManager.class);
     ResourceManager rm = mock(ResourceManager.class);
     ResourceScheduler rs = mockCapacityScheduler();
     ResourceScheduler rs = mockCapacityScheduler();
+    ApplicationACLsManager aclMgr = mockAppACLsManager();
     when(rm.getResourceScheduler()).thenReturn(rs);
     when(rm.getResourceScheduler()).thenReturn(rs);
     when(rm.getRMContext()).thenReturn(rmContext);
     when(rm.getRMContext()).thenReturn(rmContext);
+    when(rm.getApplicationACLsManager()).thenReturn(aclMgr);
     return rm;
     return rm;
   }
   }
 
 
@@ -192,6 +194,11 @@ public class TestRMWebApp {
     return cs;
     return cs;
   }
   }
 
 
+  public static ApplicationACLsManager mockAppACLsManager() {
+    Configuration conf = new Configuration();
+    return new ApplicationACLsManager(conf);
+  }
+
   static void setupQueueConfiguration(CapacitySchedulerConfiguration conf) {
   static void setupQueueConfiguration(CapacitySchedulerConfiguration conf) {
     // Define top-level queues
     // Define top-level queues
     conf.setQueues(CapacitySchedulerConfiguration.ROOT, new String[] {"a", "b", "c"});
     conf.setQueues(CapacitySchedulerConfiguration.ROOT, new String[] {"a", "b", "c"});
@@ -271,7 +278,7 @@ public class TestRMWebApp {
   public static void main(String[] args) throws Exception {
   public static void main(String[] args) throws Exception {
     // For manual testing
     // For manual testing
     WebApps.$for("yarn", new TestRMWebApp()).at(8888).inDevMode().
     WebApps.$for("yarn", new TestRMWebApp()).at(8888).inDevMode().
-        start(new RMWebApp(mockRm(101, 8, 8, 8*GiB))).joinThread();
+        start(new RMWebApp(mockRm(2500, 8, 8, 8*GiB))).joinThread();
     WebApps.$for("yarn", new TestRMWebApp()).at(8888).inDevMode().
     WebApps.$for("yarn", new TestRMWebApp()).at(8888).inDevMode().
         start(new RMWebApp(mockFifoRm(10, 1, 4, 8*GiB))).joinThread();
         start(new RMWebApp(mockFifoRm(10, 1, 4, 8*GiB))).joinThread();
   }
   }