HDFS-13359. DataXceiver hung due to the lock in FsDatasetImpl#getBlockInputStream. Contributed by Yiqun Lin.
Signed-off-by: Wei-Chiu Chuang <weichiu@apache.org> (cherry picked from commit 8a77a224c734bea0eb490f30c908748458c190c3)
This commit is contained in:
parent
2e6beb1550
commit
a7bc09c596
@ -778,7 +778,7 @@ public InputStream getBlockInputStream(ExtendedBlock b,
|
||||
long seekOffset) throws IOException {
|
||||
|
||||
ReplicaInfo info;
|
||||
synchronized(this) {
|
||||
try (AutoCloseableLock lock = datasetLock.acquire()) {
|
||||
info = volumeMap.get(b.getBlockPoolId(), b.getLocalBlock());
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user