void handleBrokerUncleanShutdown(int brokerId, List<ApiMessageAndVersion> records) {
        if (!featureControl.metadataVersion().isElrSupported()) return;
        generateLeaderAndIsrUpdates("handleBrokerUncleanShutdown", NO_LEADER, NO_LEADER, brokerId, records,
            brokersToIsrs.partitionsWithBrokerInIsr(brokerId));
        generateLeaderAndIsrUpdates("handleBrokerUncleanShutdown", NO_LEADER, NO_LEADER, brokerId, records,
            brokersToElrs.partitionsWithBrokerInElr(brokerId));
    }
Create partition change records to remove replicas from any ISR or ELR for brokers doing unclean shutdown.

@param brokerId      The broker id.
@param records       The record list to append to.
metadata/src/main/java/org/apache/kafka/controller/ReplicationControlManager.java