in src/main/java/org/apache/maven/buildcache/DefaultNormalizedModelProvider.java [113:144]
private List<Plugin> normalizePlugins(List<Plugin> plugins) {
if (plugins.isEmpty()) {
return plugins;
}
return plugins.stream()
.map(plugin -> {
Plugin copy = plugin.clone();
List<String> excludeProperties = cacheConfig.getEffectivePomExcludeProperties(copy);
if (!excludeProperties.isEmpty()) {
CacheUtils.debugPrintCollection(
LOGGER,
excludeProperties,
String.format("List of excluded properties for %s", copy.getArtifactId()),
"Excluded property");
removeBlacklistedAttributes(copy.getConfiguration(), excludeProperties);
for (PluginExecution execution : copy.getExecutions()) {
removeBlacklistedAttributes(execution.getConfiguration(), excludeProperties);
}
}
copy.setDependencies(normalizeDependencies(copy.getDependencies().stream()
.sorted(DefaultNormalizedModelProvider::compareDependencies)
.collect(Collectors.toList())));
if (multiModuleSupport.isPartOfMultiModule(
copy.getGroupId(), copy.getArtifactId(), copy.getVersion())) {
copy.setVersion(NORMALIZED_VERSION);
}
return copy;
})
.collect(Collectors.toList());
}