Package org.elasticsearch.cluster
Class ESAllocationTestCase.MockAllocationService
- java.lang.Object
-
- org.elasticsearch.common.component.AbstractComponent
-
- org.elasticsearch.cluster.routing.allocation.AllocationService
-
- org.elasticsearch.cluster.ESAllocationTestCase.MockAllocationService
-
- Enclosing class:
- ESAllocationTestCase
protected static class ESAllocationTestCase.MockAllocationService extends AllocationService
A lockAllocationService
allowing tests to override time
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.elasticsearch.cluster.routing.allocation.AllocationService
AllocationService.CommandsResult
-
-
Field Summary
-
Fields inherited from class org.elasticsearch.common.component.AbstractComponent
deprecationLogger, logger, settings
-
-
Constructor Summary
Constructors Constructor Description MockAllocationService(Settings settings, AllocationDeciders allocationDeciders, GatewayAllocator gatewayAllocator, ShardsAllocator shardsAllocator, ClusterInfoService clusterInfoService)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected long
currentNanoTime()
void
setNanoTimeOverride(long nanoTime)
-
Methods inherited from class org.elasticsearch.cluster.routing.allocation.AllocationService
applyFailedShard, applyFailedShards, applyFailedShards, applyStartedShards, buildResultAndLogHealthChange, deassociateDeadNodes, reroute, reroute, reroute, setGatewayAllocator
-
Methods inherited from class org.elasticsearch.common.component.AbstractComponent
nodeName
-
-
-
-
Constructor Detail
-
MockAllocationService
public MockAllocationService(Settings settings, AllocationDeciders allocationDeciders, GatewayAllocator gatewayAllocator, ShardsAllocator shardsAllocator, ClusterInfoService clusterInfoService)
-
-
Method Detail
-
setNanoTimeOverride
public void setNanoTimeOverride(long nanoTime)
-
currentNanoTime
protected long currentNanoTime()
- Overrides:
currentNanoTime
in classAllocationService
-
-