You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Dan Rollo <da...@gmail.com> on 2012/12/13 05:11:29 UTC

Error resolving parent pom (descriptor?) with site plugin

Hi,

I'm seeing something I can't figure out, and wondering if this is a 
known issue.

I have a multi-module maven project, which has as its parent a shared 
corporate pom (in a totally different source bank location). I can build 
this project successfully via "mvn package".

However, when I try to run the site goal, I get strange errors:

[INFO] Parent project loaded from repository: xxx:pom-parent:pom:1.0.1
...
[WARNING] Unable to find a URL to the parent project. The parent menu 
will NOT be added.
Downloading: 
http://xxx:8080/archiva/repository/cache-central/xxx/pom-parent/1.0.1/pom-parent-1.0.1.pom
mojoFailed org.apache.maven.plugins:maven-site-plugin:3.2(default-site)

and after that message, the build fails.


Just in case, I verified the parent poms site descriptor is available 
both in our shared repo, and was downloaded to the local repo.


It as if the site plugin can't find the parent pom. Here's a another 
error message:

Unable to read local module-POM
cause : SiteToolException: Unable to read local module-POM


Odder still, the "site" goal used to work fine. This problem just 
started happening after I released a new version of the parent pom, and 
updated the project to use the new released parent.

Thanks,
Dan

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Missing parent link in site, was Re: Error resolving parent pom (descriptor?) with site plugin

Posted by Lukas Theussl <lt...@apache.org>.
IIUC your findings are summed up here:
http://maven.apache.org/plugins/maven-site-plugin/faq.html#Use_of_url

HTH,
-Lukas


On 05/23/2013 04:24 AM, Dan Rollo wrote:
> Well, I never saw a response to this, and finally got tired of the missing
> 'parent' links in maven generated sites.
> 
> At some point, it appears the maven-site-plugin stopped using the parent
> projects URL, and instead looks for the parent projects distributionManagement
> -> site -> url to determine if the parent project is reachable during site
> generation.
> 
> So...to answer my own question: My workaround was to define a distMgt->site-url
> tag in the parent pom.
> 
> Due to the way m-s-p tries to inherit the parent value of this URL and then
> append it's own artifactId (which works if your parent is located above you -
> was more viable in a svn world, not so true in a git world anymore), I also have
> to re-define the distMgt->site->url again in each of my child poms to ensure the
> child site's value is correct.
> 
> Hope this might help anyone else who is wondering how to fix the message:
> [WARNING] Unable to find a URL to the parent project. The parent menu will NOT
> be added.
> 
> (My original post was about a build problem, but the missing parent link was
> also annoying...)
> 
> Dan
> 
> On 12/12/2012 11:11 PM, Dan Rollo wrote:
>> Hi,
>>
>> I'm seeing something I can't figure out, and wondering if this is a
>> known issue.
>>
>> I have a multi-module maven project, which has as its parent a shared
>> corporate pom (in a totally different source bank location). I can build
>> this project successfully via "mvn package".
>>
>> However, when I try to run the site goal, I get strange errors:
>>
>> [INFO] Parent project loaded from repository: xxx:pom-parent:pom:1.0.1
>> ...
>> [WARNING] Unable to find a URL to the parent project. The parent menu
>> will NOT be added.
>> Downloading:
>> http://xxx:8080/archiva/repository/cache-central/xxx/pom-parent/1.0.1/pom-parent-1.0.1.pom
>>
>>
>> mojoFailed org.apache.maven.plugins:maven-site-plugin:3.2(default-site)
>>
>> and after that message, the build fails.
>>
>>
>> Just in case, I verified the parent poms site descriptor is available
>> both in our shared repo, and was downloaded to the local repo.
>>
>>
>> It as if the site plugin can't find the parent pom. Here's a another
>> error message:
>>
>> Unable to read local module-POM
>> cause : SiteToolException: Unable to read local module-POM
>>
>>
>> Odder still, the "site" goal used to work fine. This problem just
>> started happening after I released a new version of the parent pom, and
>> updated the project to use the new released parent.
>>
>> Thanks,
>> Dan
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Missing parent link in site, was Re: Error resolving parent pom (descriptor?) with site plugin

Posted by Dan Rollo <da...@gmail.com>.
Well, I never saw a response to this, and finally got tired of the 
missing 'parent' links in maven generated sites.

At some point, it appears the maven-site-plugin stopped using the parent 
projects URL, and instead looks for the parent projects 
distributionManagement -> site -> url to determine if the parent project 
is reachable during site generation.

So...to answer my own question: My workaround was to define a 
distMgt->site-url tag in the parent pom.

Due to the way m-s-p tries to inherit the parent value of this URL and 
then append it's own artifactId (which works if your parent is located 
above you - was more viable in a svn world, not so true in a git world 
anymore), I also have to re-define the distMgt->site->url again in each 
of my child poms to ensure the child site's value is correct.

Hope this might help anyone else who is wondering how to fix the message:
[WARNING] Unable to find a URL to the parent project. The parent menu 
will NOT be added.

(My original post was about a build problem, but the missing parent link 
was also annoying...)

Dan

On 12/12/2012 11:11 PM, Dan Rollo wrote:
> Hi,
>
> I'm seeing something I can't figure out, and wondering if this is a
> known issue.
>
> I have a multi-module maven project, which has as its parent a shared
> corporate pom (in a totally different source bank location). I can build
> this project successfully via "mvn package".
>
> However, when I try to run the site goal, I get strange errors:
>
> [INFO] Parent project loaded from repository: xxx:pom-parent:pom:1.0.1
> ...
> [WARNING] Unable to find a URL to the parent project. The parent menu
> will NOT be added.
> Downloading:
> http://xxx:8080/archiva/repository/cache-central/xxx/pom-parent/1.0.1/pom-parent-1.0.1.pom
>
> mojoFailed org.apache.maven.plugins:maven-site-plugin:3.2(default-site)
>
> and after that message, the build fails.
>
>
> Just in case, I verified the parent poms site descriptor is available
> both in our shared repo, and was downloaded to the local repo.
>
>
> It as if the site plugin can't find the parent pom. Here's a another
> error message:
>
> Unable to read local module-POM
> cause : SiteToolException: Unable to read local module-POM
>
>
> Odder still, the "site" goal used to work fine. This problem just
> started happening after I released a new version of the parent pom, and
> updated the project to use the new released parent.
>
> Thanks,
> Dan


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org