Github user JoshRosen commented on a diff in the pull request:
https://github.com/apache/spark/pull/3574#discussion_r21418607
--- Diff: core/src/main/scala/org/apache/spark/storage/BlockManager.scala
---
@@ -1126,12 +1128,14 @@ private[spark] class BlockManager(
val (id, info, time) = (entry.getKey, entry.getValue.value,
entry.getValue.timestamp)
if (time < cleanupTime && shouldDrop(id)) {
info.synchronized {
- val level = info.level
- if (level.useMemory) { memoryStore.remove(id) }
- if (level.useDisk) { diskStore.remove(id) }
- if (level.useOffHeap) { tachyonStore.remove(id) }
- iterator.remove()
- logInfo(s"Dropped block $id")
+ if (blockInfo.get(id).isEmpty) {
--- End diff --
Similarly, I don't think that we strictly _need_ a check here since the
`remove(id)` operations are idempotent. It might be nice to log a warning if
the block has already been removed, but that might not be necessary since this
is a background cleanup call.
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]