Package org.apache.druid.metadata
Interface MetadataSupervisorManager
- All Known Implementing Classes:
SQLMetadataSupervisorManager
public interface MetadataSupervisorManager
-
Method Summary
Modifier and TypeMethodDescriptiongetAll()getAllForId(String id) Return latest supervisors (both active and terminated)Only return the latest active supervisorsOnly return the latest terminated supervisorsvoidinsert(String id, SupervisorSpec spec) intremoveTerminatedSupervisorsOlderThan(long timestamp) Remove terminated supervisors created before the given timestamp.voidstart()
-
Method Details
-
start
void start() -
insert
-
getAll
Map<String,List<VersionedSupervisorSpec>> getAll() -
getAllForId
-
getLatest
Map<String,SupervisorSpec> getLatest()Return latest supervisors (both active and terminated)- Returns:
- latest terminated supervisors
-
getLatestActiveOnly
Map<String,SupervisorSpec> getLatestActiveOnly()Only return the latest active supervisors- Returns:
- latest active supervisors
-
getLatestTerminatedOnly
Map<String,SupervisorSpec> getLatestTerminatedOnly()Only return the latest terminated supervisors- Returns:
- latest terminated supervisors
-
removeTerminatedSupervisorsOlderThan
int removeTerminatedSupervisorsOlderThan(long timestamp) Remove terminated supervisors created before the given timestamp.- Parameters:
timestamp- timestamp in milliseconds- Returns:
- number of supervisor removed
-