public static <K, I, O> Map<K, O> transformValues(Map<K, I> map, Function<I, O> transformation) {
        return map.entrySet().stream().collect(Collectors.toMap(
                Map.Entry::getKey,
                transformation.compose(Map.Entry::getValue)
        ));
    }
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