Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -217,6 +217,10 @@ protected List<MavenReportExecution> buildReportPlugin(
plugin.getArtifactId(),
plugin.getVersion(),
buff);
} else if (!hasUserDefinedReports) {
LOGGER.warn("Ignoring report plugin {}:{},"
+ " it does not contain any report goals: should be removed from reporting configuration in POM",
plugin.getArtifactId(), plugin.getVersion());
}

return reports;
Expand All @@ -225,7 +229,7 @@ protected List<MavenReportExecution> buildReportPlugin(
private boolean prepareGoals(
ReportPlugin reportPlugin, PluginDescriptor pluginDescriptor, List<GoalWithConf> goalsWithConfiguration) {
if (reportPlugin.getReportSets().isEmpty() && reportPlugin.getReports().isEmpty()) {
// by default, use every goal, which will be filtered later to only keep reporting goals
// by default, use every goal which will be filtered later to only keep reporting goals
List<MojoDescriptor> mojoDescriptors = pluginDescriptor.getMojos();
for (MojoDescriptor mojoDescriptor : mojoDescriptors) {
goalsWithConfiguration.add(new GoalWithConf(
Expand Down Expand Up @@ -292,11 +296,12 @@ private MavenReportExecution prepareReportExecution(
if (!isMavenReport(mojoExecution, pluginDescriptor)) {
if (hasUserDefinedReports) {
// reports were explicitly written in the POM
LOGGER.warn(
"Ignoring {}:{}"
LOGGER.warn("Ignoring {}:{}"
+ " goal since it is not a report: should be removed from reporting configuration in POM",
mojoExecution.getPlugin().getId(),
report.getGoal());
mojoExecution.getPlugin().getId(), report.getGoal());
} else {
LOGGER.debug("Ignoring {}:{} goal since it is not a report",
mojoExecution.getPlugin().getId(), report.getGoal());
}
return null;
}
Expand Down Expand Up @@ -411,15 +416,14 @@ private boolean isMavenReport(MojoExecution mojoExecution, PluginDescriptor plug

if (LOGGER.isDebugEnabled()) {
if (mojoDescriptor != null && mojoDescriptor.getImplementationClass() != null) {
LOGGER.debug(
"Class {} is MavenReport: ",
LOGGER.debug("Class {} is {}a MavenReport",
mojoDescriptor.getImplementationClass().getName(),
isMavenReport);
isMavenReport ? "" : "NOT ");
}

if (!isMavenReport) {
LOGGER.debug(
"Skipping non MavenReport {}",
"Skipping non-MavenReport {}",
mojoExecution.getMojoDescriptor().getId());
}
}
Expand Down