From 2b4b0e8847048850206f091c6870a02e08cfe836 Mon Sep 17 00:00:00 2001 From: Junping Du Date: Wed, 17 Dec 2014 17:40:00 -0800 Subject: [PATCH] YARN-2972. DelegationTokenRenewer thread pool never expands. Contributed by Jason Lowe --- hadoop-yarn-project/CHANGES.txt | 3 +++ .../resourcemanager/security/DelegationTokenRenewer.java | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/hadoop-yarn-project/CHANGES.txt b/hadoop-yarn-project/CHANGES.txt index 7af08b92d2..a9c28ae0b9 100644 --- a/hadoop-yarn-project/CHANGES.txt +++ b/hadoop-yarn-project/CHANGES.txt @@ -138,6 +138,9 @@ Release 2.7.0 - UNRELEASED YARN-2762. Fixed RMAdminCLI to trim and check node-label related arguments before sending to RM. (Rohith Sharmaks via jianhe) + YARN-2972. DelegationTokenRenewer thread pool never expands. (Jason Lowe + via junping_du) + OPTIMIZATIONS BUG FIXES diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-resourcemanager/src/main/java/org/apache/hadoop/yarn/server/resourcemanager/security/DelegationTokenRenewer.java b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-resourcemanager/src/main/java/org/apache/hadoop/yarn/server/resourcemanager/security/DelegationTokenRenewer.java index cca6e8df0d..f9be1bd904 100644 --- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-resourcemanager/src/main/java/org/apache/hadoop/yarn/server/resourcemanager/security/DelegationTokenRenewer.java +++ b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-resourcemanager/src/main/java/org/apache/hadoop/yarn/server/resourcemanager/security/DelegationTokenRenewer.java @@ -148,7 +148,7 @@ public class DelegationTokenRenewer extends AbstractService { .setNameFormat("DelegationTokenRenewer #%d") .build(); ThreadPoolExecutor pool = - new ThreadPoolExecutor((5 < nThreads ? 5 : nThreads), nThreads, 3L, + new ThreadPoolExecutor(nThreads, nThreads, 3L, TimeUnit.SECONDS, new LinkedBlockingQueue()); pool.setThreadFactory(tf); pool.allowCoreThreadTimeOut(true);