docs: private void expireSession(RaftSession session) {
      if (expiring.add(session.sessionId())) {
        log.debug("Expiring session due to heartbeat failure: {}", session);
        appendAndCompact(new CloseSessionEntry(raft.getTerm(), System.currentTimeMillis(), session.sessionId().id(), true, false))
            .whenCompleteAsync((entry, error) -> {
              if (error != null) {
                expiring.remove(session.sessionId());
                return;
              }
  
              appender.appendEntries(entry.index()).whenComplete((commitIndex, commitError) -> {
                raft.checkThread();
                if (isRunning()) {
                  if (commitError == null) {
                    raft.getServiceManager().<Long>apply(entry.index())
                        .whenCompleteAsync((r, e) -> expiring.remove(session.sessionId()), raft.getThreadContext());
                  } else {
                    expiring.remove(session.sessionId());
                  }
                }
              });
            }, raft.getThreadContext());
      }
    }