private void memoryTransitionTo(EpochState newState) {
        if (state != null) {
            try {
                state.close();
            } catch (IOException e) {
                throw new UncheckedIOException(
                    "Failed to transition from " + state.name() + " to " + newState.name(), e);
            }
        }

        EpochState from = state;
        state = newState;
        log.info("Completed transition to {} from {}", newState, from);
    }
Become a follower of an elected leader so that we can begin fetching.
raft/src/main/java/org/apache/kafka/raft/QuorumState.java