@ThreadSafe public class CapacityBaseRandomPolicy extends Object implements BlockLocationPolicy
BlockLocationPolicy.Factory
Constructor and Description |
---|
CapacityBaseRandomPolicy(AlluxioConfiguration conf)
Constructs a new
CapacityBaseRandomPolicy . |
Modifier and Type | Method and Description |
---|---|
WorkerNetAddress |
getWorker(GetWorkerOptions options)
Gets the worker's network address for serving operations requested for the block.
|
protected long |
randomInCapacity(long totalCapacity) |
public CapacityBaseRandomPolicy(AlluxioConfiguration conf)
CapacityBaseRandomPolicy
.conf
- Alluxio configuration@Nullable public WorkerNetAddress getWorker(GetWorkerOptions options)
BlockLocationPolicy
getWorker
in interface BlockLocationPolicy
options
- the options to get a block worker network address for a blockprotected long randomInCapacity(long totalCapacity)
Copyright © 2023. All Rights Reserved.