Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Maven searches for missing english locale of site.xml

During building a project with maven, I run into an issue generating javadoc after updating the version of its parent project.

2016-08-18 16:06:44.559 [INFO] <<< maven-javadoc-plugin:2.10.3:aggregate < generate-sources @ org.eclipse.scout.rt <<<
2016-08-18 16:06:44.560 [DEBUG] building maven31 dependency graph for org.eclipse.scout.rt:org.eclipse.scout.rt:pom:6.0.0-SNAPSHOT with Maven31DependencyGraphBuilder
2016-08-18 16:06:44.560 [DEBUG] Dependency collection stats: {ConflictMarker.analyzeTime=0, ConflictMarker.markTime=0, ConflictMarker.nodeCount=1, ConflictIdSorter.graphTime=0, ConflictIdSorter.topsortTime=0, ConflictIdSorter.conflictIdCount=0, ConflictIdSorter.conflictIdCycleCount=0, ConflictResolver.totalTime=0, ConflictResolver.conflictItemCount=0, DefaultDependencyCollector.collectTime=0, DefaultDependencyCollector.transformTime=0}
2016-08-18 16:06:44.561 [DEBUG] org.eclipse.scout.rt:org.eclipse.scout.rt:pom:6.0.0-SNAPSHOT
2016-08-18 16:06:44.636 [DEBUG]  canGenerateReport = true for project MavenProject: org.eclipse.scout.rt:org.eclipse.scout.rt:6.0.0-SNAPSHOT @ /home/<REDACTED>/workspace/org.eclipse.scout.rt.branch-6.0_nightly-sitedocs/org.eclipse.scout.rt/pom.xml
2016-08-18 16:06:44.662 [DEBUG] Computing decoration model of org.eclipse.scout.rt:org.eclipse.scout.rt:pom:6.0.0-SNAPSHOT for locale en
2016-08-18 16:06:44.662 [DEBUG] No site descriptor found for org.eclipse.scout.rt:org.eclipse.scout.rt:pom:6.0.0-SNAPSHOT
2016-08-18 16:06:44.663 [DEBUG] Looking for site descriptor of level 1 parent project: org.eclipse.scout:maven_rt_plugin_config-master:pom:2.0.7
2016-08-18 16:06:44.665 [DEBUG] Using transporter WagonTransporter with priority -1.0 for <REDACTED>
2016-08-18 16:06:44.666 [DEBUG] Using connector BasicRepositoryConnector with priority 0.0 for <REDACTED>
2016-08-18 16:06:44.666 [INFO] Downloading: <REDACTED>/org/eclipse/scout/maven_rt_plugin_config-master/2.0.7/maven_rt_plugin_config-master-2.0.7-site_en.xml
2016-08-18 16:06:45.289 [DEBUG] Writing tracking file /home/<REDACTED>/workspace/org.eclipse.scout.rt.branch-6.0_nightly-sitedocs/.repository/org/eclipse/scout/maven_rt_plugin_config-master/2.0.7/maven_rt_plugin_config-master-2.0.7-site_en.xml.lastUpdated
2016-08-18 16:06:45.597 [ERROR] Failed to execute goal org.apache.maven.plugins:maven-site-plugin:3.5.1:site (default-cli) on project org.eclipse.scout.rt: SiteToolException: The site descriptor cannot be resolved from the repository: ArtifactResolutionException: Unable to locate site descriptor: Could not transfer artifact org.eclipse.scout:maven_rt_plugin_config-master:xml:site_en:2.0.7 from/to AAA.libs.release (<REDACTED>): Access denied to: <REDACTED>/org/eclipse/scout/maven_rt_plugin_config-master/2.0.7/maven_rt_plugin_config-master-2.0.7-site_en.xml , ReasonPhrase:Forbidden.
2016-08-18 16:06:45.598 [ERROR] org.eclipse.scout:maven_rt_plugin_config-master:xml:2.0.7
2016-08-18 16:06:45.598 [ERROR] 
2016-08-18 16:06:45.598 [ERROR] from the specified remote repositories:
2016-08-18 16:06:45.598 [ERROR] AAA.libs.release (<REDACTED>, releases=true, snapshots=false),
2016-08-18 16:06:45.599 [ERROR] AAA.libs.snapshots (<REDACTED>, releases=false, snapshots=true),
2016-08-18 16:06:45.599 [ERROR] eclipse.release (https://repo.eclipse.org/content/groups/releases/, releases=true, snapshots=false),
2016-08-18 16:06:45.599 [ERROR] eclipse.snapshot (https://repo.eclipse.org/content/groups/snapshots/, releases=true, snapshots=true),
2016-08-18 16:06:45.599 [ERROR] remote-repos (<REDACTED>, releases=true, snapshots=false)

As you can see, it tries to download the maven_rt_plugin_config-master-2.0.7-site_en.xml, which in fact does not exist. There however does exist such an xml without the _en suffix...

I have specified no locales as far as I can see and there seem to be no changes in the parent project related to site or javadoc generation.

Why does Maven not fall back to the default locale?

like image 200
Patrick Avatar asked Nov 16 '25 02:11

Patrick


1 Answers

A workaround that causes the site plugin to skip looking for the missing file is to create your own site.xml site descriptor with the combine.self attribute set to override:

<project name="Your-Service" combine.self="override">
    ...
</project>

This file should live at src/site/site.xml

like image 147
Mark Avatar answered Nov 17 '25 21:11

Mark



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!