incubator-hama-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tjungb...@apache.org
Subject svn commit: r1204042 - in /incubator/hama/trunk/yarn/src/main/java/org/apache/hama/bsp: BSPApplicationMaster.java YARNBSPJob.java
Date Sat, 19 Nov 2011 19:07:14 GMT
Author: tjungblut
Date: Sat Nov 19 19:07:14 2011
New Revision: 1204042

URL: http://svn.apache.org/viewvc?rev=1204042&view=rev
Log:
Get YARN running with the release.


Modified:
    incubator/hama/trunk/yarn/src/main/java/org/apache/hama/bsp/BSPApplicationMaster.java
    incubator/hama/trunk/yarn/src/main/java/org/apache/hama/bsp/YARNBSPJob.java

Modified: incubator/hama/trunk/yarn/src/main/java/org/apache/hama/bsp/BSPApplicationMaster.java
URL: http://svn.apache.org/viewvc/incubator/hama/trunk/yarn/src/main/java/org/apache/hama/bsp/BSPApplicationMaster.java?rev=1204042&r1=1204041&r2=1204042&view=diff
==============================================================================
--- incubator/hama/trunk/yarn/src/main/java/org/apache/hama/bsp/BSPApplicationMaster.java
(original)
+++ incubator/hama/trunk/yarn/src/main/java/org/apache/hama/bsp/BSPApplicationMaster.java
Sat Nov 19 19:07:14 2011
@@ -219,8 +219,9 @@ public class BSPApplicationMaster implem
       throw new IllegalArgumentException(
           "ApplicationAttemptId not set in the environment");
     }
-    return ConverterUtils.toApplicationAttemptId(envs
-        .get(ApplicationConstants.AM_CONTAINER_ID_ENV));
+    return ConverterUtils.toContainerId(
+        envs.get(ApplicationConstants.AM_CONTAINER_ID_ENV))
+        .getApplicationAttemptId();
   }
 
   private void start() throws Exception {

Modified: incubator/hama/trunk/yarn/src/main/java/org/apache/hama/bsp/YARNBSPJob.java
URL: http://svn.apache.org/viewvc/incubator/hama/trunk/yarn/src/main/java/org/apache/hama/bsp/YARNBSPJob.java?rev=1204042&r1=1204041&r2=1204042&view=diff
==============================================================================
--- incubator/hama/trunk/yarn/src/main/java/org/apache/hama/bsp/YARNBSPJob.java (original)
+++ incubator/hama/trunk/yarn/src/main/java/org/apache/hama/bsp/YARNBSPJob.java Sat Nov 19
19:07:14 2011
@@ -202,7 +202,7 @@ public class YARNBSPJob extends BSPJob {
     Resource capability = Records.newRecord(Resource.class);
     // we have at least 3 threads, which comsumes 1mb each, for each bsptask and
     // a base usage of 100mb
-    capability.setMemory(3 * this.getNumBspTask() + 100);
+    capability.setMemory(3 * this.getNumBspTask() + conf.getInt("hama.appmaster.memory.mb",
100));
     LOG.info("Set memory for the application master to "
         + capability.getMemory() + "mb!");
     amContainer.setResource(capability);



Mime
View raw message