-
Notifications
You must be signed in to change notification settings - Fork 29k
[SPARK-27468][Core][WEBUI] BlockUpdate replication event shouldn't overwrite storage level description in the UI #24398
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 2 commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -917,8 +917,24 @@ private[spark] class AppStatusListener( | |||||||||||
| // Update the block entry in the RDD info, keeping track of the deltas above so that we | ||||||||||||
| // can update the executor information too. | ||||||||||||
| liveRDDs.get(block.rddId).foreach { rdd => | ||||||||||||
|
|
||||||||||||
| if (updatedStorageLevel.isDefined) { | ||||||||||||
| rdd.setStorageLevel(updatedStorageLevel.get) | ||||||||||||
| // Replicated block update events will have `storageLevel.replication=1`. | ||||||||||||
| // To avoid overwriting the block replicated event in the store, we need to | ||||||||||||
| // have a check for whether the event is block replication or not. | ||||||||||||
| // Default value of `storageInfo.replication = 1` and hence if | ||||||||||||
| // `storeLevel.replication = 2`, the replicated events won't overwrite in the store. | ||||||||||||
| val storageInfo = rdd.storageInfo | ||||||||||||
| val isReplicatedBlockUpdateEvent = storageLevel.replication < storageInfo.replication && | ||||||||||||
|
||||||||||||
| val updatedStorageLevel = if (storageLevel.isValid) { | |
| Some(storageLevel.description) | |
| } else { | |
| None | |
| } |
updatedStorageLevel will be None. So, it won't come to this line (L-928).Thanks
srowen marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -29,7 +29,7 @@ import org.apache.spark.JobExecutionStatus | |
| import org.apache.spark.executor.{ExecutorMetrics, TaskMetrics} | ||
| import org.apache.spark.scheduler.{AccumulableInfo, StageInfo, TaskInfo} | ||
| import org.apache.spark.status.api.v1 | ||
| import org.apache.spark.storage.RDDInfo | ||
| import org.apache.spark.storage.{RDDInfo, StorageLevel} | ||
| import org.apache.spark.ui.SparkUI | ||
| import org.apache.spark.util.AccumulatorContext | ||
| import org.apache.spark.util.collection.OpenHashSet | ||
|
|
@@ -510,6 +510,7 @@ private class LiveRDD(val info: RDDInfo) extends LiveEntity { | |
| var storageLevel: String = weakIntern(info.storageLevel.description) | ||
| var memoryUsed = 0L | ||
| var diskUsed = 0L | ||
| var storageInfo: StorageLevel = new StorageLevel() | ||
|
||
|
|
||
| private val partitions = new HashMap[String, LiveRDDPartition]() | ||
| private val partitionSeq = new RDDPartitionSeq() | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this a bug itself?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Needs more check, including impacts. Currently the fix is from UI side.