void processExpiredBrokerHeartbeat(BrokerHeartbeatRequestData request) {
        int brokerId = request.brokerId();
        clusterControl.checkBrokerEpoch(brokerId, request.brokerEpoch());
        clusterControl.heartbeatManager().touch(brokerId,
                clusterControl.brokerRegistrations().get(brokerId).fenced(),
                request.currentMetadataOffset());
        log.error("processExpiredBrokerHeartbeat: controller event queue overloaded. Timed out " +
                "heartbeat from broker {}.", brokerId);
    }
@Test
    public void testProcessExpiredBrokerHeartbeat() {
        MockTime mockTime = new MockTime(0, 0, 0);
        ReplicationControlTestContext ctx = new ReplicationControlTestContext.Builder().
                setMockTime(mockTime).
                build();
        ctx.registerBrokers(0, 1, 2);
        ctx.unfenceBrokers(0, 1, 2);

        BrokerHeartbeatRequestData heartbeatRequest = new BrokerHeartbeatRequestData().
                setBrokerId(0).
                setBrokerEpoch(100).
                setCurrentMetadataOffset(123).
                setWantShutDown(false);
        mockTime.sleep(100);
        ctx.replicationControl.processExpiredBrokerHeartbeat(heartbeatRequest);
        Optional<BrokerHeartbeatState> state =
            ctx.clusterControl.heartbeatManager().brokers().stream().
                filter(broker -> broker.id() == 0).findFirst();
        assertTrue(state.isPresent());
        assertEquals(0, state.get().id());
        assertEquals(100000000L, state.get().lastContactNs);
        assertEquals(123, state.get().metadataOffset);
    }