public boolean hasDisconnectEvent(String group) {
        List<String> consumerIdList =
                consumerHolder.getConsumerIdList(group);
        if (CollectionUtils.isNotEmpty(consumerIdList)) {
            for (String consumerId : consumerIdList) {
                if (consumerId == null) {
                    continue;
                }
                List<ConsumerEvent> eventList =
                        disconnectEventMap.get(consumerId);
                if (eventList != null) {
                    synchronized (eventList) {
                        if (CollectionUtils.isNotEmpty(eventList)) {
                            return true;
                        }
                    }
                }
            }
        }
        return false;
    }
Check if disconnect event map have event

@param group    the group name needs a query
@return true if disconnect event map not empty otherwise false
inlong-tubemq/tubemq-server/src/main/java/org/apache/inlong/tubemq/server/master/nodemanage/nodeconsumer/ConsumerEventManager.java