pgaref commented on a change in pull request #75:
URL: https://github.com/apache/tez/pull/75#discussion_r469886670



##########
File path: tez-dag/src/main/java/org/apache/tez/dag/app/DAGAppMaster.java
##########
@@ -621,8 +622,13 @@ public synchronized void serviceInit(final Configuration 
conf) throws Exception
       }
     }
 
-    rawExecutor = Executors.newCachedThreadPool(new 
ThreadFactoryBuilder().setDaemon(true)
-        .setNameFormat("App Shared Pool - " + "#%d").build());
+    int thread_count = 
conf.getInt(TezConfiguration.TEZ_AM_DAG_APPCONTEXT_THREAD_COUNT_LIMIT,
+            TezConfiguration.TEZ_AM_DAG_APPCONTEXT_THREAD_COUNT_LIMIT_DEFAULT);
+    // NOTE: LinkedBlockingQueue does not have a capacity Limit and can thus
+    // occupy large memory chunks when numerous Runables are pending for 
execution
+    rawExecutor = new ThreadPoolExecutor(1, thread_count,

Review comment:
       Thanks for taking a look Attila! You are totally right, just confirmed 
this with a test and updated the code.




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to