Closed frankietsang closed 3 years ago
NiFi has a StandardRestrictedSSLContextService and a StandardSSLContextService. The description of the second in NiFi 1.11.4 says that the Restricted version should be preferred. I may be that the regular one was removed in NiFi 1.12.0.
It seems that the ClientAuth
class has been moved from being nested in org.apache.nifi.ssl.SSLContextService
to being the standalone class org.apache.nifi.security.util.ClientAuth
. From looking at the changes between 1.11.4 to 1.12.0, this particular problem seems to be easy to change. Overall, though, the changes between the two nifi versions seem rather extensive. Is anyone committed to making the required changes to the MarkLogic NiFi processors so that they can be used with 1.12.0 yet?
Not sure if this resolves your issue here. But, I tried Nifi 1.12.1 with the 1.9.1.4 NARs. Everything seems to start up fine. There seems to be a fix here for Keystores. Perhaps there is something in these changes that help.
https://cwiki.apache.org/confluence/display/NIFI/Release+Notes#ReleaseNotes-Version1.12.1
@awanczowski Thank you for reporting this. I can confirm that I can load the 1.9.1.4 NARs into NiFi 1.12.1 as well!
FYI, I did test the connection using an SSL Context with JKS Keystore. It worked hitting a public Data Hub Service without issue.
I believe this issue can be closed. I've been working with NiFi 1.12.1 and the 1.9.1.4 seems to be starting up without a problem.
I tried to use Marklogic nifi incubator 1.9.1.4 with nifi 1.12 and was not able to start nifi. Once I switched to nifi 1.11.4, I could start nifi with Marklogic nifi incubator 1.9.1.4 without any issue.
From the nifi-app.log, I found the following error:
2020-09-13 15:29:55,946 ERROR [main] org.apache.nifi.NiFi Failure to launch NiFi due to java.util.ServiceConfigurationError: org.apache.nifi.controller.ControllerService: Provider org.apache.nifi.marklogic.controller.DefaultMarkLogicDatabaseClientService could not be instantiated java.util.ServiceConfigurationError: org.apache.nifi.controller.ControllerService: Provider org.apache.nifi.marklogic.controller.DefaultMarkLogicDatabaseClientService could not be instantiated at java.util.ServiceLoader.fail(ServiceLoader.java:232) at java.util.ServiceLoader.access$100(ServiceLoader.java:185) at java.util.ServiceLoader$LazyIterator.nextService(ServiceLoader.java:384) at java.util.ServiceLoader$LazyIterator.next(ServiceLoader.java:404) at java.util.ServiceLoader$1.next(ServiceLoader.java:480) at org.apache.nifi.nar.StandardExtensionDiscoveringManager.loadExtensions(StandardExtensionDiscoveringManager.java:156) at org.apache.nifi.nar.StandardExtensionDiscoveringManager.discoverExtensions(StandardExtensionDiscoveringManager.java:131) at org.apache.nifi.nar.StandardExtensionDiscoveringManager.discoverExtensions(StandardExtensionDiscoveringManager.java:117) at org.apache.nifi.web.server.JettyServer.start(JettyServer.java:1048) at org.apache.nifi.NiFi.(NiFi.java:158)
at org.apache.nifi.NiFi.(NiFi.java:72)
at org.apache.nifi.NiFi.main(NiFi.java:301)
Caused by: java.lang.NoClassDefFoundError: org/apache/nifi/ssl/SSLContextService$ClientAuth
at java.lang.Class.getDeclaredConstructors0(Native Method)
at java.lang.Class.privateGetDeclaredConstructors(Class.java:2671)
at java.lang.Class.getConstructor0(Class.java:3075)
at java.lang.Class.newInstance(Class.java:412)
at java.util.ServiceLoader$LazyIterator.nextService(ServiceLoader.java:380)
... 9 common frames omitted
Caused by: java.lang.ClassNotFoundException: org.apache.nifi.ssl.SSLContextService$ClientAuth
at java.net.URLClassLoader.findClass(URLClassLoader.java:382)
at java.lang.ClassLoader.loadClass(ClassLoader.java:418)
at java.lang.ClassLoader.loadClass(ClassLoader.java:351)
... 14 common frames omitted
2020-09-13 15:29:55,947 INFO [Thread-1] org.apache.nifi.NiFi Initiating shutdown of Jetty web server...
2020-09-13 15:29:55,948 INFO [Thread-1] org.apache.nifi.NiFi Jetty web server shutdown completed (nicely or otherwise).