hadoop git commit: HADOOP-12958. PhantomReference for filesystem statistics can trigger OOM. Contributed by Sangjin Lee (cherry picked from commit 9a09200a1f5f752e266d4fb8e0c808073080bde8)

2016-03-25 Thread jlowe
Repository: hadoop
Updated Branches:
  refs/heads/branch-2.6 160a8c74d -> c092a8c1b


HADOOP-12958. PhantomReference for filesystem statistics can trigger OOM. 
Contributed by Sangjin Lee
(cherry picked from commit 9a09200a1f5f752e266d4fb8e0c808073080bde8)


Project: http://git-wip-us.apache.org/repos/asf/hadoop/repo
Commit: http://git-wip-us.apache.org/repos/asf/hadoop/commit/c092a8c1
Tree: http://git-wip-us.apache.org/repos/asf/hadoop/tree/c092a8c1
Diff: http://git-wip-us.apache.org/repos/asf/hadoop/diff/c092a8c1

Branch: refs/heads/branch-2.6
Commit: c092a8c1bb071fb708e20d9a66ea2fd6195f18e7
Parents: 160a8c7
Author: Jason Lowe <jl...@apache.org>
Authored: Fri Mar 25 23:05:29 2016 +
Committer: Jason Lowe <jl...@apache.org>
Committed: Fri Mar 25 23:05:29 2016 +

--
 hadoop-common-project/hadoop-common/CHANGES.txt  | 3 +++
 .../src/main/java/org/apache/hadoop/fs/FileSystem.java   | 8 
 2 files changed, 7 insertions(+), 4 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/hadoop/blob/c092a8c1/hadoop-common-project/hadoop-common/CHANGES.txt
--
diff --git a/hadoop-common-project/hadoop-common/CHANGES.txt 
b/hadoop-common-project/hadoop-common/CHANGES.txt
index 5782165..39f14ca 100644
--- a/hadoop-common-project/hadoop-common/CHANGES.txt
+++ b/hadoop-common-project/hadoop-common/CHANGES.txt
@@ -27,6 +27,9 @@ Release 2.6.5 - UNRELEASED
 HADOOP-12589. Fix intermittent test failure of TestCopyPreserveFlag
 (iwasakims)
 
+HADOOP-12958. PhantomReference for filesystem statistics can trigger OOM
+(Sangjin Lee via jlowe)
+
 Release 2.6.4 - 2016-02-11
 
   INCOMPATIBLE CHANGES

http://git-wip-us.apache.org/repos/asf/hadoop/blob/c092a8c1/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FileSystem.java
--
diff --git 
a/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FileSystem.java
 
b/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FileSystem.java
index 64efe66..ffee0fd 100644
--- 
a/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FileSystem.java
+++ 
b/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FileSystem.java
@@ -20,7 +20,7 @@ package org.apache.hadoop.fs;
 import java.io.Closeable;
 import java.io.FileNotFoundException;
 import java.io.IOException;
-import java.lang.ref.PhantomReference;
+import java.lang.ref.WeakReference;
 import java.lang.ref.ReferenceQueue;
 import java.net.URI;
 import java.net.URISyntaxException;
@@ -2889,7 +2889,7 @@ public abstract class FileSystem extends Configured 
implements Closeable {
 
 /**
  * Set of all thread-local data areas.  Protected by the Statistics lock.
- * The references to the statistics data are kept using phantom references
+ * The references to the statistics data are kept using weak references
  * to the associated threads. Proper clean-up is performed by the cleaner
  * thread when the threads are garbage collected.
  */
@@ -2942,11 +2942,11 @@ public abstract class FileSystem extends Configured 
implements Closeable {
 }
 
 /**
- * A phantom reference to a thread that also includes the data associated
+ * A weak reference to a thread that also includes the data associated
  * with that thread. On the thread being garbage collected, it is enqueued
  * to the reference queue for clean-up.
  */
-private class StatisticsDataReference extends PhantomReference {
+private class StatisticsDataReference extends WeakReference {
   private final StatisticsData data;
 
   public StatisticsDataReference(StatisticsData data, Thread thread) {



hadoop git commit: HADOOP-12958. PhantomReference for filesystem statistics can trigger OOM. Contributed by Sangjin Lee (cherry picked from commit 9a09200a1f5f752e266d4fb8e0c808073080bde8)

2016-03-25 Thread jlowe
Repository: hadoop
Updated Branches:
  refs/heads/branch-2.7 a112c0138 -> 02e81caa2


HADOOP-12958. PhantomReference for filesystem statistics can trigger OOM. 
Contributed by Sangjin Lee
(cherry picked from commit 9a09200a1f5f752e266d4fb8e0c808073080bde8)


Project: http://git-wip-us.apache.org/repos/asf/hadoop/repo
Commit: http://git-wip-us.apache.org/repos/asf/hadoop/commit/02e81caa
Tree: http://git-wip-us.apache.org/repos/asf/hadoop/tree/02e81caa
Diff: http://git-wip-us.apache.org/repos/asf/hadoop/diff/02e81caa

Branch: refs/heads/branch-2.7
Commit: 02e81caa216ea45741c611c2b016e69e9c208704
Parents: a112c01
Author: Jason Lowe <jl...@apache.org>
Authored: Fri Mar 25 23:03:39 2016 +
Committer: Jason Lowe <jl...@apache.org>
Committed: Fri Mar 25 23:03:39 2016 +

--
 hadoop-common-project/hadoop-common/CHANGES.txt  | 3 +++
 .../src/main/java/org/apache/hadoop/fs/FileSystem.java   | 8 
 2 files changed, 7 insertions(+), 4 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/hadoop/blob/02e81caa/hadoop-common-project/hadoop-common/CHANGES.txt
--
diff --git a/hadoop-common-project/hadoop-common/CHANGES.txt 
b/hadoop-common-project/hadoop-common/CHANGES.txt
index a2381fa..c51378a 100644
--- a/hadoop-common-project/hadoop-common/CHANGES.txt
+++ b/hadoop-common-project/hadoop-common/CHANGES.txt
@@ -76,6 +76,9 @@ Release 2.7.3 - UNRELEASED
 
 HADOOP-12688. Fix deadlinks in Compatibility.md. (Gabor Liptak via 
aajisaka)
 
+HADOOP-12958. PhantomReference for filesystem statistics can trigger OOM
+(Sangjin Lee via jlowe)
+
 Release 2.7.2 - 2016-01-25
 
   INCOMPATIBLE CHANGES

http://git-wip-us.apache.org/repos/asf/hadoop/blob/02e81caa/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FileSystem.java
--
diff --git 
a/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FileSystem.java
 
b/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FileSystem.java
index 35c28b7..fac3c40 100644
--- 
a/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FileSystem.java
+++ 
b/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FileSystem.java
@@ -20,7 +20,7 @@ package org.apache.hadoop.fs;
 import java.io.Closeable;
 import java.io.FileNotFoundException;
 import java.io.IOException;
-import java.lang.ref.PhantomReference;
+import java.lang.ref.WeakReference;
 import java.lang.ref.ReferenceQueue;
 import java.net.URI;
 import java.net.URISyntaxException;
@@ -2950,7 +2950,7 @@ public abstract class FileSystem extends Configured 
implements Closeable {
 
 /**
  * Set of all thread-local data areas.  Protected by the Statistics lock.
- * The references to the statistics data are kept using phantom references
+ * The references to the statistics data are kept using weak references
  * to the associated threads. Proper clean-up is performed by the cleaner
  * thread when the threads are garbage collected.
  */
@@ -3003,11 +3003,11 @@ public abstract class FileSystem extends Configured 
implements Closeable {
 }
 
 /**
- * A phantom reference to a thread that also includes the data associated
+ * A weak reference to a thread that also includes the data associated
  * with that thread. On the thread being garbage collected, it is enqueued
  * to the reference queue for clean-up.
  */
-private class StatisticsDataReference extends PhantomReference {
+private class StatisticsDataReference extends WeakReference {
   private final StatisticsData data;
 
   public StatisticsDataReference(StatisticsData data, Thread thread) {



hadoop git commit: HADOOP-12958. PhantomReference for filesystem statistics can trigger OOM. Contributed by Sangjin Lee (cherry picked from commit 9a09200a1f5f752e266d4fb8e0c808073080bde8)

2016-03-25 Thread jlowe
Repository: hadoop
Updated Branches:
  refs/heads/branch-2.8 1a194f875 -> 25b476e93


HADOOP-12958. PhantomReference for filesystem statistics can trigger OOM. 
Contributed by Sangjin Lee
(cherry picked from commit 9a09200a1f5f752e266d4fb8e0c808073080bde8)


Project: http://git-wip-us.apache.org/repos/asf/hadoop/repo
Commit: http://git-wip-us.apache.org/repos/asf/hadoop/commit/25b476e9
Tree: http://git-wip-us.apache.org/repos/asf/hadoop/tree/25b476e9
Diff: http://git-wip-us.apache.org/repos/asf/hadoop/diff/25b476e9

Branch: refs/heads/branch-2.8
Commit: 25b476e93b718dad9a7bb68c700624e15d5f1e5c
Parents: 1a194f8
Author: Jason Lowe <jl...@apache.org>
Authored: Fri Mar 25 22:56:49 2016 +
Committer: Jason Lowe <jl...@apache.org>
Committed: Fri Mar 25 23:00:18 2016 +

--
 .../src/main/java/org/apache/hadoop/fs/FileSystem.java   | 8 
 1 file changed, 4 insertions(+), 4 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/hadoop/blob/25b476e9/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FileSystem.java
--
diff --git 
a/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FileSystem.java
 
b/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FileSystem.java
index fa2816e..200e893 100644
--- 
a/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FileSystem.java
+++ 
b/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FileSystem.java
@@ -20,7 +20,7 @@ package org.apache.hadoop.fs;
 import java.io.Closeable;
 import java.io.FileNotFoundException;
 import java.io.IOException;
-import java.lang.ref.PhantomReference;
+import java.lang.ref.WeakReference;
 import java.lang.ref.ReferenceQueue;
 import java.net.URI;
 import java.net.URISyntaxException;
@@ -3070,7 +3070,7 @@ public abstract class FileSystem extends Configured 
implements Closeable {
 
 /**
  * Set of all thread-local data areas.  Protected by the Statistics lock.
- * The references to the statistics data are kept using phantom references
+ * The references to the statistics data are kept using weak references
  * to the associated threads. Proper clean-up is performed by the cleaner
  * thread when the threads are garbage collected.
  */
@@ -3123,11 +3123,11 @@ public abstract class FileSystem extends Configured 
implements Closeable {
 }
 
 /**
- * A phantom reference to a thread that also includes the data associated
+ * A weak reference to a thread that also includes the data associated
  * with that thread. On the thread being garbage collected, it is enqueued
  * to the reference queue for clean-up.
  */
-private class StatisticsDataReference extends PhantomReference {
+private class StatisticsDataReference extends WeakReference {
   private final StatisticsData data;
 
   public StatisticsDataReference(StatisticsData data, Thread thread) {



hadoop git commit: HADOOP-12958. PhantomReference for filesystem statistics can trigger OOM. Contributed by Sangjin Lee (cherry picked from commit 9a09200a1f5f752e266d4fb8e0c808073080bde8)

2016-03-25 Thread jlowe
Repository: hadoop
Updated Branches:
  refs/heads/branch-2 c58599acb -> 5e823d839


HADOOP-12958. PhantomReference for filesystem statistics can trigger OOM. 
Contributed by Sangjin Lee
(cherry picked from commit 9a09200a1f5f752e266d4fb8e0c808073080bde8)


Project: http://git-wip-us.apache.org/repos/asf/hadoop/repo
Commit: http://git-wip-us.apache.org/repos/asf/hadoop/commit/5e823d83
Tree: http://git-wip-us.apache.org/repos/asf/hadoop/tree/5e823d83
Diff: http://git-wip-us.apache.org/repos/asf/hadoop/diff/5e823d83

Branch: refs/heads/branch-2
Commit: 5e823d839db643efdaf228eb7da742aa728bed99
Parents: c58599a
Author: Jason Lowe <jl...@apache.org>
Authored: Fri Mar 25 22:56:49 2016 +
Committer: Jason Lowe <jl...@apache.org>
Committed: Fri Mar 25 22:59:14 2016 +

--
 .../src/main/java/org/apache/hadoop/fs/FileSystem.java   | 8 
 1 file changed, 4 insertions(+), 4 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/hadoop/blob/5e823d83/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FileSystem.java
--
diff --git 
a/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FileSystem.java
 
b/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FileSystem.java
index ca5f3a3..e3f8ea8 100644
--- 
a/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FileSystem.java
+++ 
b/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FileSystem.java
@@ -20,7 +20,7 @@ package org.apache.hadoop.fs;
 import java.io.Closeable;
 import java.io.FileNotFoundException;
 import java.io.IOException;
-import java.lang.ref.PhantomReference;
+import java.lang.ref.WeakReference;
 import java.lang.ref.ReferenceQueue;
 import java.net.URI;
 import java.net.URISyntaxException;
@@ -3119,7 +3119,7 @@ public abstract class FileSystem extends Configured 
implements Closeable {
 
 /**
  * Set of all thread-local data areas.  Protected by the Statistics lock.
- * The references to the statistics data are kept using phantom references
+ * The references to the statistics data are kept using weak references
  * to the associated threads. Proper clean-up is performed by the cleaner
  * thread when the threads are garbage collected.
  */
@@ -3172,11 +3172,11 @@ public abstract class FileSystem extends Configured 
implements Closeable {
 }
 
 /**
- * A phantom reference to a thread that also includes the data associated
+ * A weak reference to a thread that also includes the data associated
  * with that thread. On the thread being garbage collected, it is enqueued
  * to the reference queue for clean-up.
  */
-private class StatisticsDataReference extends PhantomReference {
+private class StatisticsDataReference extends WeakReference {
   private final StatisticsData data;
 
   public StatisticsDataReference(StatisticsData data, Thread thread) {