Our Community is getting an upgrade! To get everything ready for the relaunch, we’ll be placing the site in read-only mode starting September 21st.
We really appreciate your understanding while we get things set up behind the scenes. Catch up on all the exciting details about the move here.
Need help or have questions? Drop us a line at [email protected]

Archives of Support Questions (Read Only)

This is an archived board for historical reference. Information and links may no longer be available or relevant
Announcements
This board is archived and read-only for historical reference. To ask a new question, please post a new topic on the appropriate active board.

How to inject Custom Confluent Schema Registry controller service?

avatar
Expert Contributor

Hello,

Since our downstream applications use Confluent Schema Registry, I implemented a custom ConfluentSchemaRegistry service by referring the HWXSchemaRegistry. I put the .nar file into NIFI_HOME/lib folder. I can find this custom service in the Controller Service panel.

However, when I'd like to inject this service to the "Schema Registry" property of CSVReader or AvroReader, there are only two default schema registries to choose, without the one I added. Please see the attached picture.

How to make my custom schema registry service available for the other services to inject? In other words, how to make it available in the drop-down list in the attached picture?

BTW, I am using Apache NiFi v1.3.

Thanks.

16554-nifi-custom-services.png

1 ACCEPTED SOLUTION

avatar
Master Guru

Your custom NAR needs to have a NAR dependency in the pom.xml on the standard services API:

 <dependency>
            <groupId>org.apache.nifi</groupId>
            <artifactId>nifi-standard-services-api-nar</artifactId>
            <type>nar</type>
        </dependency>

If you can share your custom NAR code or pom files I can take a look.

View solution in original post

3 REPLIES 3

avatar
Master Guru

Your custom NAR needs to have a NAR dependency in the pom.xml on the standard services API:

 <dependency>
            <groupId>org.apache.nifi</groupId>
            <artifactId>nifi-standard-services-api-nar</artifactId>
            <type>nar</type>
        </dependency>

If you can share your custom NAR code or pom files I can take a look.

avatar
Expert Contributor

Yes, after add this dependency. It works. Thanks.

avatar
Master Guru

@Alvin Jin

Also, I know you already implemented a custom service, but there is also some work here by one of the Apache NiFi committers: https://github.com/apache/nifi/pull/1938