public Map<Long, ProducerStateEntry> activeProducers() {
        return Collections.unmodifiableMap(producers);
    }
Get an unmodifiable map of active producers.
storage/src/main/java/org/apache/kafka/storage/internals/log/ProducerStateManager.java