public interface SlotPoolGateway extends RpcGateway
SlotPool
.Modifier and Type | Method and Description |
---|---|
Future<SimpleSlot> |
allocateSlot(ScheduledUnit task,
ResourceProfile resources,
Iterable<TaskManagerLocation> locationPreferences,
Time timeout) |
void |
connectToResourceManager(UUID resourceManagerLeaderId,
ResourceManagerGateway resourceManagerGateway)
Connects the SlotPool to the given ResourceManager.
|
void |
disconnectResourceManager()
Disconnects the slot pool from its current Resource Manager.
|
void |
failAllocation(AllocationID allocationID,
Exception cause) |
Future<Boolean> |
offerSlot(AllocatedSlot slot) |
Future<Iterable<SlotOffer>> |
offerSlots(Iterable<Tuple2<AllocatedSlot,SlotOffer>> offers) |
void |
registerTaskManager(ResourceID resourceID) |
void |
releaseTaskManager(ResourceID resourceID) |
void |
returnAllocatedSlot(Slot slot) |
void |
suspend() |
getAddress, getHostname
void suspend()
void connectToResourceManager(UUID resourceManagerLeaderId, ResourceManagerGateway resourceManagerGateway)
resourceManagerLeaderId
- The leader session ID of the resource manager.resourceManagerGateway
- The RPC gateway for the resource manager.void disconnectResourceManager()
The slot pool will still be able to serve slots from its internal pool.
void registerTaskManager(ResourceID resourceID)
void releaseTaskManager(ResourceID resourceID)
Future<Boolean> offerSlot(AllocatedSlot slot)
void failAllocation(AllocationID allocationID, Exception cause)
Future<SimpleSlot> allocateSlot(ScheduledUnit task, ResourceProfile resources, Iterable<TaskManagerLocation> locationPreferences, Time timeout)
void returnAllocatedSlot(Slot slot)
Copyright © 2014–2018 The Apache Software Foundation. All rights reserved.