markap14 commented on code in PR #10874:
URL: https://github.com/apache/nifi/pull/10874#discussion_r2933623258
##########
nifi-framework-bundle/nifi-framework/nifi-framework-core/src/main/java/org/apache/nifi/controller/repository/WriteAheadFlowFileRepository.java:
##########
@@ -153,6 +158,8 @@ public WriteAheadFlowFileRepository(final NiFiProperties
nifiProperties) {
retainOrphanedFlowFiles = orphanedFlowFileProperty == null ||
Boolean.parseBoolean(orphanedFlowFileProperty);
this.maxCharactersToCache =
nifiProperties.getIntegerProperty(FLOWFILE_REPO_CACHE_SIZE, DEFAULT_CACHE_SIZE);
+ final long maxAppendableClaimLength =
DataUnit.parseDataSize(nifiProperties.getMaxAppendableClaimSize(),
DataUnit.B).longValue();
+ truncationThreshold = Math.min(1_000_000, maxAppendableClaimLength);
Review Comment:
Is just a "magic number" ... if someone goes in and sets Max Appendable to
something large like 10 MB, we still want to consider truncating smaller
values. 1 MB seems reasonable.
--
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.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]