hadoop-common-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tomwh...@apache.org
Subject svn commit: r1042047 - in /hadoop/common/trunk: CHANGES.txt src/java/org/apache/hadoop/security/token/delegation/AbstractDelegationTokenSecretManager.java
Date Fri, 03 Dec 2010 22:59:23 GMT
Author: tomwhite
Date: Fri Dec  3 22:59:23 2010
New Revision: 1042047

URL: http://svn.apache.org/viewvc?rev=1042047&view=rev
Log:
HADOOP-6939. Inconsistent lock ordering in AbstractDelegationTokenSecretManager. Contributed
by Todd Lipcon.

Modified:
    hadoop/common/trunk/CHANGES.txt
    hadoop/common/trunk/src/java/org/apache/hadoop/security/token/delegation/AbstractDelegationTokenSecretManager.java

Modified: hadoop/common/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/CHANGES.txt?rev=1042047&r1=1042046&r2=1042047&view=diff
==============================================================================
--- hadoop/common/trunk/CHANGES.txt (original)
+++ hadoop/common/trunk/CHANGES.txt Fri Dec  3 22:59:23 2010
@@ -34,6 +34,9 @@ Trunk (unreleased changes)
     HADOOP-7045. TestDU fails on systems with local file systems with 
     extended attributes. (eli)
 
+    HADOOP-6939. Inconsistent lock ordering in
+    AbstractDelegationTokenSecretManager. (Todd Lipcon via tomwhite)
+
 Release 0.22.0 - Unreleased
 
   INCOMPATIBLE CHANGES

Modified: hadoop/common/trunk/src/java/org/apache/hadoop/security/token/delegation/AbstractDelegationTokenSecretManager.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/src/java/org/apache/hadoop/security/token/delegation/AbstractDelegationTokenSecretManager.java?rev=1042047&r1=1042046&r2=1042047&view=diff
==============================================================================
--- hadoop/common/trunk/src/java/org/apache/hadoop/security/token/delegation/AbstractDelegationTokenSecretManager.java
(original)
+++ hadoop/common/trunk/src/java/org/apache/hadoop/security/token/delegation/AbstractDelegationTokenSecretManager.java
Fri Dec  3 22:59:23 2010
@@ -95,11 +95,13 @@ extends AbstractDelegationTokenIdentifie
   }
 
   /** should be called before this object is used */
-  public synchronized void startThreads() throws IOException {
+  public void startThreads() throws IOException {
     updateCurrentKey();
-    running = true;
-    tokenRemoverThread = new Daemon(new ExpiredTokenRemover());
-    tokenRemoverThread.start();
+    synchronized (this) {
+      running = true;
+      tokenRemoverThread = new Daemon(new ExpiredTokenRemover());
+      tokenRemoverThread.start();
+    }
   }
   
   /** 



Mime
View raw message