public static <I, T, C> C combineCollections(
            Collection<I> collection,
            Function<I, Collection<T>> extractCollection,
            Collector<T, ?, C> collector
    ) {
        return collection.stream()
                .map(extractCollection)
                .flatMap(Collection::stream)
                .collect(collector);
    }
Apply a specified transformation {@link Function} to every value in a Map.
@param map the Map to be transformed
@param transformation the transformation function
@return the transformed Map
@param <K> the key type
@param <I> the pre-transform value type
@param <O> the post-transform value type
connect/runtime/src/main/java/org/apache/kafka/connect/util/ConnectUtils.java