[
https://issues.apache.org/jira/browse/NIFI-10111?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Mark Payne updated NIFI-10111:
------------------------------
Fix Version/s: 1.17.0
> When unpacking NARs, provide ability to unpack into uber jar to avoid using
> too many open file handles
> ------------------------------------------------------------------------------------------------------
>
> Key: NIFI-10111
> URL: https://issues.apache.org/jira/browse/NIFI-10111
> Project: Apache NiFi
> Issue Type: Improvement
> Components: Core Framework, Documentation & Website, NiFi
> Stateless
> Reporter: Mark Payne
> Assignee: Mark Payne
> Priority: Major
> Fix For: 1.17.0
>
> Time Spent: 10m
> Remaining Estimate: 0h
>
> When we unpack a NAR file, we expand all .jar files within it into the
> working directory. We then create a NAR ClassLoader for the NAR. The NAR
> ClassLoader extends URLClassLoader. As a result, we end up with a ClassLoader
> that holds an open file handle for every JAR file (and potentially other
> files) that gets unpacked.
> This can result in NiFi needing to use a lot of open file handles.
> When using Stateless NiFi, this is of particular concern, as it may need to
> run in more constrained environments, since it's intended to be embedded.
> We can significantly reduce the number of open file handles by unpacking each
> NAR into a single "Uber Jar File" instead of individual files. While this is
> particularly of concern for for Stateless NiFi, it may provide benefits to
> NiFi also. But for NiFi, it should not be "on by default". Users should have
> to opt into it via an entry in nifi.properties.
--
This message was sent by Atlassian Jira
(v8.20.7#820007)