use of org.apache.hadoop.hbase.backup.BackupInfo.BackupState in project hbase by apache.
the class BackupSystemTable method getBackupHistory.
/**
* Get all completed backup information (in desc order by time)
* @param onlyCompleted true, if only successfully completed sessions
* @return history info of BackupCompleteData
* @throws IOException exception
*/
public ArrayList<BackupInfo> getBackupHistory(boolean onlyCompleted) throws IOException {
if (LOG.isTraceEnabled()) {
LOG.trace("get backup history from backup system table");
}
ArrayList<BackupInfo> list;
BackupState state = onlyCompleted ? BackupState.COMPLETE : BackupState.ANY;
list = getBackupInfos(state);
return BackupUtils.sortHistoryListDesc(list);
}
Aggregations