micheal-o commented on code in PR #47875:
URL: https://github.com/apache/spark/pull/47875#discussion_r1735547289
##########
sql/core/src/main/scala/org/apache/spark/sql/execution/streaming/state/RocksDB.scala:
##########
@@ -251,6 +251,11 @@ class RocksDB(
}
}
+ @GuardedBy("acquireLock")
+ private val rocksDBFileMapping: RocksDBFileMapping = new RocksDBFileMapping()
+
+ private val snapshots = new ConcurrentLinkedQueue[RocksDBSnapshot]()
+
Review Comment:
nit: at least one-line comment describing what each val is being used for
will be nice for readers
##########
sql/core/src/main/scala/org/apache/spark/sql/execution/streaming/state/RocksDB.scala:
##########
@@ -1005,6 +986,125 @@ class RocksDB(
override protected def logName: String = s"${super.logName} $loggingId"
}
+// uniquely identifies a Snapshot. Multiple snapshots created for same version
will
+// use a different dfsFilesUUID, and hence will have different
RocksDBVersionSnapshotInfo
+case class RocksDBVersionSnapshotInfo(version: Long, dfsFilesUUID: String)
Review Comment:
nit: `RocksDBVersionSnapshotId` may be better to make it clear that it is a
unique identifier
##########
sql/core/src/main/scala/org/apache/spark/sql/execution/streaming/state/RocksDB.scala:
##########
@@ -251,6 +251,11 @@ class RocksDB(
}
}
+ @GuardedBy("acquireLock")
+ private val rocksDBFileMapping: RocksDBFileMapping = new RocksDBFileMapping()
+
+ private val snapshots = new ConcurrentLinkedQueue[RocksDBSnapshot]()
Review Comment:
nit: might be better to make the name clear i.e. `snapshotsToUploadQueue`
--
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]