HBASE-24423 No need to get lock in canSplit because hasReferences will get lock too
This commit is contained in:
parent
285e59af25
commit
29c59c0ba8
|
@ -2061,17 +2061,12 @@ public class HStore implements Store, HeapSize, StoreConfigInformation,
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean canSplit() {
|
public boolean canSplit() {
|
||||||
this.lock.readLock().lock();
|
// Not split-able if we find a reference store file present in the store.
|
||||||
try {
|
boolean result = !hasReferences();
|
||||||
// Not split-able if we find a reference store file present in the store.
|
if (!result) {
|
||||||
boolean result = !hasReferences();
|
LOG.trace("Not splittable; has references: {}", this);
|
||||||
if (!result) {
|
|
||||||
LOG.trace("Not splittable; has references: {}", this);
|
|
||||||
}
|
|
||||||
return result;
|
|
||||||
} finally {
|
|
||||||
this.lock.readLock().unlock();
|
|
||||||
}
|
}
|
||||||
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Reference in New Issue