Zoltán Kornél Török created NIFI-12539:
------------------------------------------
Summary: Nifi Registry not accept connection in secure mode
Key: NIFI-12539
URL: https://issues.apache.org/jira/browse/NIFI-12539
Project: Apache NiFi
Issue Type: Bug
Components: NiFi Registry
Affects Versions: 2.0.0-M1, 2.0.0
Reporter: Zoltán Kornél Török
h3. Problem description
When you configure nifi-registry to be secure and try to connect to it via
[https://127.0.0.1:18443/nifi-registry] it will throw the following exceptions
in the log (and not load the ui and also api calls not works):
{code:java}
2023-12-22 10:48:14,340 WARN [NiFi Registry Web Server-46]
org.eclipse.jetty.io.ManagedSelector Could not accept
java.nio.channels.SocketChannel[closed]: java.lang.NoClassDefFoundError:
org/eclipse/jetty/io/ssl/SslConnection$DecryptedEndPoint {code}
h3. What cause the problem?
The problem exists since
[https://issues.apache.org/jira/projects/NIFI/issues/NIFI-12434] is merged. In
that ticket the spring version is increased and also the Jetty from 11.0.18 to
12.0.3. That cause the problem, because in case of nifi the jetty version
remained 11.0.18 and there is a code which use
{color:#000000}SslConnection{color}.{color:#000000}DecryptedEndPoint{color}
class:
[https://github.com/apache/nifi/blob/main/nifi-commons/nifi-jetty-configuration/src/main/java/org/apache/nifi/jetty/configuration/connector/alpn/StandardALPNProcessor.java#L62]
In case of nifi this is working fine, but the same maven module used in
nifi-registry as well and in Jetty 12.0.3 the
{color:#000000}SslConnection{color}.{color:#000000}DecryptedEndPoint{color}
class is removed, that is why we got the NoClassDefFoundError and see this.
h3. Possible solutions?
* increase jetty version in nifi and refactor code to support new version
* Duplicate code for nifi-registry and modify for it (not recommended as code
duplication later could cause trouble)
* Revert back code change (not recommended as sooner / later definitly need to
increase versions)
--
This message was sent by Atlassian Jira
(v8.20.10#820010)