hadoop-hdfs-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From omal...@apache.org
Subject svn commit: r1089314 - in /hadoop/hdfs/branches/yahoo-merge: CHANGES.txt src/java/org/apache/hadoop/hdfs/HftpFileSystem.java
Date Wed, 06 Apr 2011 06:22:26 GMT
Author: omalley
Date: Wed Apr  6 06:22:26 2011
New Revision: 1089314

URL: http://svn.apache.org/viewvc?rev=1089314&view=rev
Log:
commit 6684168c5f0eaefde00c5a30e3a5cfe14d69266b
Author: Owen O'Malley <omalley@apache.org>
Date:   Tue Apr 5 11:34:11 2011 -0700

    HDFS-1656. Fixes an issue to do with fetching of delegation tokens in
    HftpFileSystem. Contributed by Kan Zhang.
    
    Conflicts:
    
    	YAHOO-CHANGES.txt

Modified:
    hadoop/hdfs/branches/yahoo-merge/CHANGES.txt
    hadoop/hdfs/branches/yahoo-merge/src/java/org/apache/hadoop/hdfs/HftpFileSystem.java

Modified: hadoop/hdfs/branches/yahoo-merge/CHANGES.txt
URL: http://svn.apache.org/viewvc/hadoop/hdfs/branches/yahoo-merge/CHANGES.txt?rev=1089314&r1=1089313&r2=1089314&view=diff
==============================================================================
--- hadoop/hdfs/branches/yahoo-merge/CHANGES.txt (original)
+++ hadoop/hdfs/branches/yahoo-merge/CHANGES.txt Wed Apr  6 06:22:26 2011
@@ -244,7 +244,10 @@ Trunk (unreleased changes)
 
     HDFS-1684. Balancer cannot start with with multiple namenodes.  (szetszwo)
 
-    HDFS-1445: Fast Snapshot via batch hardlinks. (Matt Foley)
+    HDFS-1445. Fast Snapshot via batch hardlinks. (Matt Foley)
+
+    HDFS-1656. Fixes an issue to do with fetching of delegation tokens in
+    HftpFileSystem. (Kan Zhang via ddas)
 
 Release 0.22.0 - Unreleased
 

Modified: hadoop/hdfs/branches/yahoo-merge/src/java/org/apache/hadoop/hdfs/HftpFileSystem.java
URL: http://svn.apache.org/viewvc/hadoop/hdfs/branches/yahoo-merge/src/java/org/apache/hadoop/hdfs/HftpFileSystem.java?rev=1089314&r1=1089313&r2=1089314&view=diff
==============================================================================
--- hadoop/hdfs/branches/yahoo-merge/src/java/org/apache/hadoop/hdfs/HftpFileSystem.java (original)
+++ hadoop/hdfs/branches/yahoo-merge/src/java/org/apache/hadoop/hdfs/HftpFileSystem.java Wed
Apr  6 06:22:26 2011
@@ -179,9 +179,6 @@ public class HftpFileSystem extends File
         }
       }
       
-      //Renew TGT if needed
-      ugi.reloginFromKeytab();
-      
       //since we don't already have a token, go get one over https
       if (delegationToken == null) {
         delegationToken = 
@@ -193,8 +190,10 @@ public class HftpFileSystem extends File
   
 
   @Override
-  public Token<?> getDelegationToken(final String renewer) throws IOException {
+  public synchronized Token<?> getDelegationToken(final String renewer) throws IOException
{
     try {
+      //Renew TGT if needed
+      ugi.reloginFromKeytab();
       return ugi.doAs(new PrivilegedExceptionAction<Token<?>>() {
         public Token<?> run() throws IOException {
           Credentials c;



Mime
View raw message