bakaid commented on a change in pull request #715: MINIFICPP-1126 - Reduce sawtooth in memory usage of rocksdb flowfile … URL: https://github.com/apache/nifi-minifi-cpp/pull/715#discussion_r371703217
########## File path: extensions/rocksdb-repos/FlowFileRepository.cpp ########## @@ -69,14 +68,8 @@ void FlowFileRepository::flush() { batch.Delete(keys[i]); } - - if (db_->Write(rocksdb::WriteOptions(), &batch).ok()) { - logger_->log_trace("Decrementing %u from a repo size of %u", decrement_total, repo_size_.load()); - if (decrement_total > repo_size_.load()) { - repo_size_ = 0; - } else { - repo_size_ -= decrement_total; - } + if (!db_->Write(rocksdb::WriteOptions(), &batch).ok()) { + logger_->log_warn("Failed to execute batch operation when flushing FlowFileRepository"); Review comment: Agreed, but I think it is something we would need, done properly. Is there a follow-up issues for it? ---------------------------------------------------------------- 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: us...@infra.apache.org With regards, Apache Git Services