I think the issue is you are building with the latest NAR plugin, but
then you have a dependency on an older version of nifi-api.

Not sure how your project is setup, but try changing to nifi-api
1.9.2. If you are using a project generated from the archetype, then
you may be getting nifi-api from your root pom having a parent on
nifi-nar-bundles. If that is the case then use nifi-nar-bundles 1.9.2.

We probably should document somewhere that the 1.3.1 NAR plugin is
dependent on nifi-api 1.9.x. Not sure where the best place to do that
would be.

On Thu, May 30, 2019 at 2:41 PM Russell Bateman <r...@windofkeltia.com> wrote:
>
> I'm sorry. Too much copying and pasting. I'm using 1.3.1 of the
> nifi-nar-maven-plugin. Would you reconsider the question on that basis?
>
> On 5/30/19 11:05 AM, Bryan Bende wrote:
> > 3.5.1 is not a valid version of the NAR plugin. The current released
> > version used by NiFi master is 1.3.1 ...
> >
> > https://github.com/apache/nifi/blob/master/pom.xml#L492
> >
> > Does the same thing happen using 1.3.1?
> >
> > On Thu, May 30, 2019 at 1:02 PM Russell Bateman <r...@windofkeltia.com> 
> > wrote:
> >> In /pom.xml/, I have:
> >>
> >> <plugin>
> >>     <groupId>*org.apache.nifi*</groupId>
> >>     <artifactId>*nifi-nar-maven-plugin*</artifactId>
> >>     <version>*3.5.1*</version>
> >>     <extensions>*true*</extensions>
> >> </plugin>
> >>
> >>
> >> I get this, which isn't fatal, when my NAR is built. I would like
> >>
> >>      a) to know to what "extension(s)" this refers (related to the
> >>      plug-in configuration in /pom.xml/?),
> >>      b) where to put extension documentation such that it will be picked
> >>      up or
> >>      c) what I can do to eliminate this warning in favor of there not
> >>      being any extensions or extensions documentation, but which
> >>      satisfies nifi-nar-maven-plugin and keeps it quiet about it.
> >>
> >> I didn't get this using some previous version of the plug-in.
> >>
> >> Thanks.
> >>
> >> [INFO] Copying commons-httpclient-3.1.jar to
> >> /home/russ/sandboxes/nifi-pipeline.master/imat-pipeline-nar/target/classes/META-INF/bundled-dependencies/commons-httpclient-3.1.jar
> >> [INFO] etc....
> >> [INFO] Generating documentation for NiFi extensions in the NAR...
> >> [INFO] Found NAR dependency of
> >> org.apache.nifi:nifi-dbcp-service-nar:nar:1.9.2:compile
> >> [INFO] Found NAR dependency of
> >> org.apache.nifi:nifi-standard-services-api-nar:nar:1.9.2:compile
> >> [INFO] Found NAR dependency of
> >> org.apache.nifi:nifi-jetty-bundle:nar:1.9.2:compile
> >> [INFO] Found a dependency on version 1.9.2 of NiFi API
> >> [*WARNING*] Could not generate extensions' documentation
> >> *org.apache.maven.plugin.MojoExecutionException: Failed to create
> >> Extension Documentation*
> >>       at org.apache.nifi.NarMojo.generateDocumentation (NarMojo.java:596)
> >>       at org.apache.nifi.NarMojo.execute (NarMojo.java:499)
> >>       at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo
> >> (DefaultBuildPluginManager.java:137)
> >>       at org.apache.maven.lifecycle.internal.MojoExecutor.execute
> >> (MojoExecutor.java:210)
> >>       at org.apache.maven.lifecycle.internal.MojoExecutor.execute
> >> (MojoExecutor.java:156)
> >>       at org.apache.maven.lifecycle.internal.MojoExecutor.execute
> >> (MojoExecutor.java:148)
> >>       at
> >> org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject
> >> (LifecycleModuleBuilder.java:117)
> >>       at
> >> org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject
> >> (LifecycleModuleBuilder.java:81)
> >>       at
> >> org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build
> >> (SingleThreadedBuilder.java:56)
> >>       at org.apache.maven.lifecycle.internal.LifecycleStarter.execute
> >> (LifecycleStarter.java:128)
> >>       at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:305)
> >>       at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:192)
> >>       at org.apache.maven.DefaultMaven.execute (DefaultMaven.java:105)
> >>       at org.apache.maven.cli.MavenCli.execute (MavenCli.java:956)
> >>       at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:288)
> >>       at org.apache.maven.cli.MavenCli.main (MavenCli.java:192)
> >>       at sun.reflect.NativeMethodAccessorImpl.invoke0 (Native Method)
> >>       at sun.reflect.NativeMethodAccessorImpl.invoke
> >> (NativeMethodAccessorImpl.java:62)
> >>       at sun.reflect.DelegatingMethodAccessorImpl.invoke
> >> (DelegatingMethodAccessorImpl.java:43)
> >>       at java.lang.reflect.Method.invoke (Method.java:498)
> >>       at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced
> >> (Launcher.java:289)
> >>       at org.codehaus.plexus.classworlds.launcher.Launcher.launch
> >> (Launcher.java:229)
> >>       at
> >> org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode
> >> (Launcher.java:415)
> >>       at org.codehaus.plexus.classworlds.launcher.Launcher.main
> >> (Launcher.java:356)
> >> *Caused by: java.lang.NoSuchMethodException:
> >> org.apache.nifi.documentation.xml.XmlDocumentationWriter.initialize(org.apache.nifi.components.ConfigurableComponent)*
> >>       at java.lang.Class.getMethod (Class.java:1786)
> >>       at org.apache.nifi.NarMojo.writeDocumentation (NarMojo.java:631)
> >>       at org.apache.nifi.NarMojo.writeDocumentation (NarMojo.java:605)
> >>       at org.apache.nifi.NarMojo.generateDocumentation (NarMojo.java:577)
> >>       at org.apache.nifi.NarMojo.execute (NarMojo.java:499)
> >>       at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo
> >> (DefaultBuildPluginManager.java:137)
> >>       at org.apache.maven.lifecycle.internal.MojoExecutor.execute
> >> (MojoExecutor.java:210)
> >>       at org.apache.maven.lifecycle.internal.MojoExecutor.execute
> >> (MojoExecutor.java:156)
> >>       at org.apache.maven.lifecycle.internal.MojoExecutor.execute
> >> (MojoExecutor.java:148)
> >>       at
> >> org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject
> >> (LifecycleModuleBuilder.java:117)
> >>       at
> >> org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject
> >> (LifecycleModuleBuilder.java:81)
> >>       at
> >> org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build
> >> (SingleThreadedBuilder.java:56)
> >>       at org.apache.maven.lifecycle.internal.LifecycleStarter.execute
> >> (LifecycleStarter.java:128)
> >>       at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:305)
> >>       at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:192)
> >>       at org.apache.maven.DefaultMaven.execute (DefaultMaven.java:105)
> >>       at org.apache.maven.cli.MavenCli.execute (MavenCli.java:956)
> >>       at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:288)
> >>       at org.apache.maven.cli.MavenCli.main (MavenCli.java:192)
> >>       at sun.reflect.NativeMethodAccessorImpl.invoke0 (Native Method)
> >>       at sun.reflect.NativeMethodAccessorImpl.invoke
> >> (NativeMethodAccessorImpl.java:62)
> >>       at sun.reflect.DelegatingMethodAccessorImpl.invoke
> >> (DelegatingMethodAccessorImpl.java:43)
> >>       at java.lang.reflect.Method.invoke (Method.java:498)
> >>       at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced
> >> (Launcher.java:289)
> >>       at org.codehaus.plexus.classworlds.launcher.Launcher.launch
> >> (Launcher.java:229)
> >>       at
> >> org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode
> >> (Launcher.java:415)
> >>       at org.codehaus.plexus.classworlds.launcher.Launcher.main
> >> (Launcher.java:356)
> >> [INFO] Building jar:
> >> /home/russ/sandboxes/nifi-pipeline.master/imat-pipeline-nar/target/imat-pipeline-2.0.0.nar
> >>
>

Reply via email to