HDFS-10245. Fix the findbugs warnings in branch-2.7. Contributed by Brahma Reddy Battula.
This commit is contained in:
parent
0bb23e22ce
commit
076215024b
|
@ -161,6 +161,9 @@ Release 2.7.3 - UNRELEASED
|
|||
HDFS-9555. LazyPersistFileScrubber should still sleep if there are errors
|
||||
in the clear progress (Phil Yang via kihwal)
|
||||
|
||||
HDFS-10245. Fix the findbugs warnings in branch-2.7.
|
||||
(Brahma Reddy Battula via aajisaka)
|
||||
|
||||
Release 2.7.2 - 2016-01-25
|
||||
|
||||
INCOMPATIBLE CHANGES
|
||||
|
|
|
@ -82,6 +82,17 @@
|
|||
<Bug pattern="REC_CATCH_EXCEPTION" />
|
||||
</Match>
|
||||
|
||||
<!--
|
||||
we don't need to synchronize out in newStreamForAppend method because
|
||||
out.streamer cannot be touched by other threads. It is false-positive.
|
||||
-->
|
||||
<Match>
|
||||
<Class name="org.apache.hadoop.hdfs.DFSOutputStream" />
|
||||
<Method name="newStreamForAppend" />
|
||||
<Field name="streamer" />
|
||||
<Bug pattern="IS2_INCONSISTENT_SYNC" />
|
||||
</Match>
|
||||
|
||||
<!--
|
||||
lastAppliedTxid is carefully unsynchronized in the BackupNode in a couple spots.
|
||||
See the comments in BackupImage for justification.
|
||||
|
|
|
@ -2368,7 +2368,7 @@ public class DFSOutputStream extends FSOutputSummer
|
|||
}
|
||||
|
||||
@VisibleForTesting
|
||||
ExtendedBlock getBlock() {
|
||||
synchronized ExtendedBlock getBlock() {
|
||||
return streamer.getBlock();
|
||||
}
|
||||
|
||||
|
@ -2386,7 +2386,7 @@ public class DFSOutputStream extends FSOutputSummer
|
|||
* @return The times have retried to recover pipeline, for the same packet.
|
||||
*/
|
||||
@VisibleForTesting
|
||||
int getPipelineRecoveryCount() {
|
||||
synchronized int getPipelineRecoveryCount() {
|
||||
return streamer.pipelineRecoveryCount;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue