HADOOP-9964. Fix deadlocks in TestHttpServer by synchronize ReflectionUtils.printThreadInfo. (Junping Du via llu)

git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/branches/branch-2@1527651 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Luke Lu 2013-09-30 17:01:51 +00:00
parent e26ac59ca0
commit 4ff49a7516
2 changed files with 4 additions and 1 deletions

View File

@ -61,6 +61,9 @@ Release 2.3.0 - UNRELEASED
BUG FIXES
HADOOP-9964. Fix deadlocks in TestHttpServer by synchronize
ReflectionUtils.printThreadInfo. (Junping Du via llu)
HADOOP-9582. Non-existent file to "hadoop fs -conf" doesn't throw error
(Ashwin Shankar via jlowe)

View File

@ -154,7 +154,7 @@ private static String getTaskName(long id, String name) {
* @param stream the stream to
* @param title a string title for the stack trace
*/
public static void printThreadInfo(PrintWriter stream,
public synchronized static void printThreadInfo(PrintWriter stream,
String title) {
final int STACK_DEPTH = 20;
boolean contention = threadBean.isThreadContentionMonitoringEnabled();