natural commented on a change in pull request #3594: NIFI-3833 Support for
Encrypted Flow File Repositories
URL: https://github.com/apache/nifi/pull/3594#discussion_r323572363
##########
File path:
nifi-commons/nifi-write-ahead-log/src/main/java/org/apache/nifi/wali/HashMapSnapshot.java
##########
@@ -264,10 +267,11 @@ public synchronized void writeSnapshot(final
SnapshotCapture<T> snapshot) throws
}
// Write to the partial file.
- try (final FileOutputStream fileOut = new
FileOutputStream(getPartialFile());
Review comment:
My intent was to avoid having to check for a null cipher key at every call
site, but as you point out, some of those sites are within a
try-with-resources, making the static method that I implemented... questionable.
I've replaced the static method with a ctor and some support methods, and
updated all of the call sites with a null check.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services