HeartSaVioR commented on code in PR #41089:
URL: https://github.com/apache/spark/pull/41089#discussion_r1187106223
##########
sql/core/src/main/scala/org/apache/spark/sql/execution/streaming/state/RocksDBFileManager.scala:
##########
@@ -371,7 +371,8 @@ class RocksDBFileManager(
// Get the immutable files used in previous versions, as some of those
uploaded files can be
// reused for this version
logInfo(s"Saving RocksDB files to DFS for $version")
- val prevFilesToSizes = versionToRocksDBFiles.values.asScala.flatten.map {
f =>
+ val prevFilesToSizes = versionToRocksDBFiles.asScala.filterKeys(_ !=
version)
Review Comment:
`_ < version` to fit with above code comment.
Btw, my preference is actually invalidating entries of cache for the version
if we figure out the version will be reprocessed. (Say, invalidating all
entries of cache for versions where version in entry > parameter in
RocksDB.load().) But I agree this is broader fix which may not be necessary,
since listing up cache entries are only performed here.
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]