@Override
    public void delete(Procedure<?> parentProc, long[] subProcIds) {
      synchronized (procMap) {
        try {
          procMap.put(parentProc.getProcId(), ProcedureUtil.convertToProtoProcedure(parentProc));
          for (long procId : subProcIds) {
            procMap.remove(procId);
          }
        } catch (IOException e) {
          throw new UncheckedIOException(e);
        }
      }
    }
Testcase for HBASE-28210, where we persist the procedure which has been inserted later to
{@link RootProcedureState} first and then crash, and then cause holes in stack ids when loading,
and finally fail the start up of master.
hbase-procedure/src/test/java/org/apache/hadoop/hbase/procedure2/TestStackIdHoles.java