public class ProbabilisticBufferReviewer extends Object implements Reviewer
StorageDir
by early stopping putting
new blocks into it.
The existing blocks in the StorageDir
will likely read more data in and expand in size.
We want to leave some space for the expansion, to lower the chance of eviction.Reviewer.Factory
Constructor and Description |
---|
ProbabilisticBufferReviewer()
Constructor the instance from configuration.
|
Modifier and Type | Method and Description |
---|---|
boolean |
acceptAllocation(StorageDirView dirView)
Reviews an allocation proposed by the
Allocator . |
public ProbabilisticBufferReviewer()
public boolean acceptAllocation(StorageDirView dirView)
Reviewer
Allocator
.
Returning true means the allocation is accepted.
Returning false meanes the allocation is rejected.acceptAllocation
in interface Reviewer
dirView
- the storage dir that the block is allocated toCopyright © 2023. All Rights Reserved.