Github user squito commented on a diff in the pull request:
https://github.com/apache/spark/pull/2851#discussion_r26393960
--- Diff: core/src/main/scala/org/apache/spark/storage/StorageUtils.scala
---
@@ -224,8 +299,14 @@ class StorageStatus(val blockManagerId:
BlockManagerId, val maxMem: Long) {
} else {
_rddStorageInfo(rddId) = (newMem, newDisk, newTachyon, level)
}
+ case BroadcastBlockId(broadcastId, _) =>
+ if (newMem + newDisk + newTachyon == 0) {
+ _broadcastStorageInfo.remove(broadcastId)
+ } else {
+ _broadcastStorageInfo(broadcastId) = (newMem, newDisk,
newTachyon)
+ }
--- End diff --
I think you could use the same `case rddOrBroadcastBlockId @ (_:
BroadcastBlockId | _: RDDBlockId)` pattern here to combine both matches in this
method ... its subjective whether its worth it or not, but I think it would be
cleaner.
---
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]