public class InstanceManager extends Object
| Constructor and Description |
|---|
InstanceManager()
Creates an new instance manager.
|
public void shutdown()
public boolean reportHeartBeat(InstanceID instanceId)
public InstanceID registerTaskManager(TaskManagerGateway taskManagerGateway, TaskManagerLocation taskManagerLocation, HardwareDescription resources, int numberOfSlots)
taskManagerGateway - gateway to the task managertaskManagerLocation - Location info of the TaskManagerresources - Hardware description of the TaskManagernumberOfSlots - Number of available slots on the TaskManagerpublic void unregisterTaskManager(InstanceID instanceId, boolean terminated)
InstanceListener about the dead instance.instanceId - TaskManager which is about to be marked dead.public void unregisterAllTaskManagers()
public boolean isRegistered(InstanceID instanceId)
public boolean isRegistered(ResourceID resourceId)
public int getNumberOfRegisteredTaskManagers()
public int getTotalNumberOfSlots()
public int getNumberOfAvailableSlots()
public Collection<Instance> getAllRegisteredInstances()
public Instance getRegisteredInstanceById(InstanceID instanceID)
public Instance getRegisteredInstance(ResourceID ref)
public void addInstanceListener(InstanceListener listener)
public void removeInstanceListener(InstanceListener listener)
Copyright © 2014–2019 The Apache Software Foundation. All rights reserved.