From e849be2d31b6b5cda14f3c19b5469ca4d2742d7d Mon Sep 17 00:00:00 2001 From: Uma Maheswara Rao G Date: Tue, 5 May 2015 19:25:21 +0530 Subject: [PATCH] HDFS-8324. Add trace info to DFSClient#getErasureCodingZoneInfo(..). Contributed by Vinayakumar B --- hadoop-hdfs-project/hadoop-hdfs/CHANGES-HDFS-EC-7285.txt | 3 +++ .../src/main/java/org/apache/hadoop/hdfs/DFSClient.java | 3 +++ 2 files changed, 6 insertions(+) diff --git a/hadoop-hdfs-project/hadoop-hdfs/CHANGES-HDFS-EC-7285.txt b/hadoop-hdfs-project/hadoop-hdfs/CHANGES-HDFS-EC-7285.txt index ef760fcd9c..a8df3f268f 100644 --- a/hadoop-hdfs-project/hadoop-hdfs/CHANGES-HDFS-EC-7285.txt +++ b/hadoop-hdfs-project/hadoop-hdfs/CHANGES-HDFS-EC-7285.txt @@ -169,3 +169,6 @@ HDFS-8242. Erasure Coding: XML based end-to-end test for ECCli commands (Rakesh R via vinayakumarb) + + HDFS-8324. Add trace info to DFSClient#getErasureCodingZoneInfo(..) (vinayakumarb via + umamahesh) diff --git a/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/DFSClient.java b/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/DFSClient.java index 722bb39695..84e7871e53 100644 --- a/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/DFSClient.java +++ b/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/DFSClient.java @@ -3358,11 +3358,14 @@ TraceScope getSrcDstTraceScope(String description, String src, String dst) { */ public ECZoneInfo getErasureCodingZoneInfo(String src) throws IOException { checkOpen(); + TraceScope scope = getPathTraceScope("getErasureCodingZoneInfo", src); try { return namenode.getErasureCodingZoneInfo(src); } catch (RemoteException re) { throw re.unwrapRemoteException(FileNotFoundException.class, AccessControlException.class, UnresolvedPathException.class); + } finally { + scope.close(); } } }