Holding the fsnamesytem lock while calling logSync is unnecessary and decrease NameNode performance.
This is fixed in HDFS-988 (which generally cleans up synchronization and safemode checks throughout FSN). I need to do a unit test over there, then it should be good to commit.
Good find Hairong. Assuming HDFS-988 goes into 21 I think we can close this, unless Todd do you want to pull out that particular fix to a patch for this jira?
Since HDFS-988 is marked blocker, and I should have a unit test for it ready soon, I'm marking this one as duplicate.