Hi,
maybe I am wrong here, but I have a problem running pldoc with maven 3's "mvn site". I receive the following error and I am not sure what causes the error. Maybe it is because of Maven 3.
Thanks in advance,
Frank
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-site-plugin:3.0-beta-3:site (default-site) on project loyalty-structure: failed to get Reports: Unable to parse configuration of mojo net.sourceforge.pldoc:maven-pldoc-plugin:2.0:pldoc: Setter net.sourceforge.pldoc.mojo.PLDoc.setReportOutputDirectory( java.lang.Class ) threw exception when called with parameter 'D:\LP_SVN\LPS\LMS_GLOBAL\loyalty\structure\target\site\apidocs': null: InvocationTargetException: NullPointerException -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.apache.maven.plugins:maven-site-plugin:3.0-beta-3:site (default-site) on project loyalty-structure: failed to get Reports
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:217)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:84)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:59)
at org.apache.maven.lifecycle.internal.LifecycleStarter.singleThreadedBuild(LifecycleStarter.java:183)
at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:161)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:319)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:156)
at org.apache.maven.cli.MavenCli.execute(MavenCli.java:534)
at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:196)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:141)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:290)
at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:230)
at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:409)
at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:352)
Caused by: org.apache.maven.plugin.MojoExecutionException: failed to get Reports
at org.apache.maven.plugins.site.DefaultMavenReportExecutor.buildMavenReports(DefaultMavenReportExecutor.java:298)
at org.apache.maven.plugins.site.AbstractSiteRenderingMojo.getReports(AbstractSiteRenderingMojo.java:208)
at org.apache.maven.plugins.site.SiteMojo.execute(SiteMojo.java:105)
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:107)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:209)
... 19 more
Caused by: org.apache.maven.plugin.PluginConfigurationException: Unable to parse configuration of mojo net.sourceforge.pldoc:maven-pldoc-plugin:2.0:pldoc: Setter net.sourceforge.pldoc.mojo.PLDoc.setReportOutputDirectory( java.lang.Class ) threw exception when called with parameter 'D:\LP_SVN\LPS\LMS_GLOBAL\loyalty\structure\target\site\apidocs': null
at org.apache.maven.plugin.internal.DefaultMavenPluginManager.populatePluginFields(DefaultMavenPluginManager.java:593)
at org.apache.maven.plugin.internal.DefaultMavenPluginManager.getConfiguredMojo(DefaultMavenPluginManager.java:525)
at org.apache.maven.plugins.site.DefaultMavenReportExecutor.getConfiguredMavenReport(DefaultMavenReportExecutor.java:339)
at org.apache.maven.plugins.site.DefaultMavenReportExecutor.buildMavenReports(DefaultMavenReportExecutor.java:268)
... 23 more
Caused by: org.codehaus.plexus.component.configurator.ComponentConfigurationException: Setter net.sourceforge.pldoc.mojo.PLDoc.setReportOutputDirectory( java.lang.Class ) threw exception when called with parameter 'D:\LP_SVN\LPS\LMS_GLOBAL\loyalty\structure\target\site\apidocs':null
at org.codehaus.plexus.component.configurator.converters.ComponentValueSetter.setValueUsingSetter(ComponentValueSetter.java:199)
at org.codehaus.plexus.component.configurator.converters.ComponentValueSetter.configure(ComponentValueSetter.java:224)
at org.codehaus.plexus.component.configurator.converters.composite.ObjectWithFieldsConverter.processConfiguration(ObjectWithFieldsConverter.java:137)
at org.codehaus.plexus.component.configurator.BasicComponentConfigurator.configureComponent(BasicComponentConfigurator.java:56)
at org.apache.maven.plugin.internal.DefaultMavenPluginManager.populatePluginFields(DefaultMavenPluginManager.java:563)
... 26 more
Caused by: java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.codehaus.plexus.component.configurator.converters.ComponentValueSetter.setValueUsingSetter(ComponentValueSetter.java:186)
... 30 more
Caused by: java.lang.NullPointerException
at java.lang.String.endsWith(String.java:1296)
at net.sourceforge.pldoc.mojo.PLDoc.setReportOutputDirectory(PLDoc.java:188)
... 35 more
[ERROR]
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
Works under maven 3.0.3 - pldoc.sourceforge.net is created using the site plugin
So maybe the problem is not related to Maven 3?
Any idea?
Try refreshing the source code; the project description (pldoc/trunk/pom.xml) has changed quite a lot since March.
Secondly, there has been a few releases since March: if you just want to run pldoc, you can download one of the bundles and run it without having to compile the source code.
if you _DO_ compile it, be aware that it now takes _MUCH_ longer to compile.
But it does cope with more source code.
Good luck and please add a comment to says whether or not the problem still exists.
Summary
Check source code out of Subversion repository
svn checkout https://pldoc.svn.sourceforge.net/svnroot/pldoc/pldoc/tags/pldoc-0.9.4 pldoc
Compile and package the code
mvn -U package
cd test
./pldoc_test.bat to ./pldoc_test.sh
Great, release 2.3 works properly for me.
Thanks to Stuart.
Many years later I had the same issue:
Solution : Add a dummy jdbc link
e.g.
Last edit: Wonno 2020-01-13