}
@Override
public Repo<Master> call(long tid, Master master) throws Exception {
Text tableIdText = new Text(tableId);
MergeInfo mergeInfo = master.getMergeInfo(tableIdText);
log.info("removing merge information " + mergeInfo);
master.clearMergeState(tableIdText);
Utils.unreserveTable(tableId, tid, true);
// We can't add entries to the metadata table if it is offline for this merge.
// If the delete entries for the metadata table were in the root tablet, it would work just fine
// but all the delete entries go into the end of the metadata table. Work around: add the
// delete entries after the merge completes.
if (mergeInfo.getOperation().equals(Operation.MERGE) && tableId.equals(Constants.METADATA_TABLE_ID)) {
return new MakeDeleteEntries();
}
return null;
}