You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@nifi.apache.org by Vincent Russell <vi...@gmail.com> on 2017/06/01 14:00:47 UTC

Re: Extending ListenHTTP

Thank you Bryan.  That didn't work, but copying the code from ListenHTTP
worked.



On Wed, May 31, 2017 at 12:42 PM, Bryan Bende <bb...@gmail.com> wrote:

> Hi Vincent,
>
> Generally it is not really expected to extend a processor in
> nifi-standard-processors, but if you really wanted to then the missing
> piece would be for your NAR pom to have a NAR dependency on
> nifi-standard-nar:
>
> <dependency>
>   <group>org.apache.nifi</group>
>   <artifactId>nifi-standard-nar</group>
>   <type>nar</type>
> </dependency>
>
> Doing this makes nifi-standard-nar become the parent NAR of your NAR,
> and therefore all of the classpath from nifi-standard-nar is now
> visible to your NAR at runtime, which or may not be desirable.
>
> Usually its best to separate out common logic into abstract classes
> and utility code in nifi-processor-utils, or in some cases just
> copying and pasting the processor and modifying it.
>
> Hope that helps.
>
> -Bryan
>
>
> On Wed, May 31, 2017 at 11:55 AM, Vincent Russell
> <vi...@gmail.com> wrote:
> > All,
> >
> > I'm using nifi version 0.7.1.
> >
> > Hello I have extended the ListenHTTP processor so that I can have a
> custom
> > servlet that grabs the issuerDN from the cert that posting to the
> endpoint.
> >
> > However when jetty attempts to start I get a
> > "javax.servlet.UnavailableException"   It appears that this is being
> caused
> > because my nar classes are in a different classloader than the jetty
> > classes.
> >
> > My nar has a provided dependency on nifi-standard-processors.   Is this
> not
> > the way to do this?
> >
> > Does anyone have any pointers for how I can fix this?
> >
> > Thanks,
> >
> >
>