protected synchronized void addRollbackStep(Procedure<Env> proc) {
    if (proc.isFailed()) {
      state = State.FAILED;
    }
    if (subprocStack == null) {
      subprocStack = new ArrayList<>();
    }
    proc.addStackIndex(subprocStack.size());
    LOG.trace("Add procedure {} as the {}th rollback step", proc, subprocStack.size());
    subprocStack.add(proc);
  }
Called by the {@link ProcedureExecutor} after the procedure step is completed, to add the step
to the rollback list (or procedure stack).
iotdb-core/confignode/src/main/java/org/apache/iotdb/confignode/procedure/RootProcedureStack.java