presto-main/src/main/java/io/prestosql/util/MoreMaps.java/MoreMaps/mergeMaps
class MoreMaps:    public static <K, V> Map<K, V> mergeMaps(Stream<Map<K, V>> mapStream, BinaryOperator<V> merger)
    {
        return mapStream
                .map(Map::entrySet)
                .flatMap(Collection::stream)
                .collect(toMap(Map.Entry::getKey, Map.Entry::getValue, merger));
    }