diff options
author | Matei Zaharia <matei@eecs.berkeley.edu> | 2013-03-04 12:08:31 -0800 |
---|---|---|
committer | Matei Zaharia <matei@eecs.berkeley.edu> | 2013-03-04 12:08:31 -0800 |
commit | 9f0dc829cbaa9aa5011fb917010d13ea5e0a19d7 (patch) | |
tree | 4775aae896ce5a56aaf1452d3ad03617d95dc192 /core/src | |
parent | 04fb81ffe51df16fd950253223041695e602144e (diff) | |
download | spark-9f0dc829cbaa9aa5011fb917010d13ea5e0a19d7.tar.gz spark-9f0dc829cbaa9aa5011fb917010d13ea5e0a19d7.tar.bz2 spark-9f0dc829cbaa9aa5011fb917010d13ea5e0a19d7.zip |
Fix TaskMetrics not being serializable
Diffstat (limited to 'core/src')
-rw-r--r-- | core/src/main/scala/spark/executor/TaskMetrics.scala | 19 |
1 files changed, 13 insertions, 6 deletions
diff --git a/core/src/main/scala/spark/executor/TaskMetrics.scala b/core/src/main/scala/spark/executor/TaskMetrics.scala index 800305cd6c..b9c07830f5 100644 --- a/core/src/main/scala/spark/executor/TaskMetrics.scala +++ b/core/src/main/scala/spark/executor/TaskMetrics.scala @@ -1,14 +1,16 @@ package spark.executor -class TaskMetrics{ +class TaskMetrics extends Serializable { /** * Time taken on the executor to deserialize this task */ var executorDeserializeTime: Int = _ + /** * Time the executor spends actually running the task (including fetching shuffle data) */ var executorRunTime:Int = _ + /** * The number of bytes this task transmitted back to the driver as the TaskResult */ @@ -23,49 +25,54 @@ class TaskMetrics{ * If this task writes to shuffle output, metrics on the written shuffle data will be collected here */ var shuffleWriteMetrics: Option[ShuffleWriteMetrics] = None - } object TaskMetrics { - private[spark] def empty() : TaskMetrics = new TaskMetrics + private[spark] def empty(): TaskMetrics = new TaskMetrics } -class ShuffleReadMetrics { +class ShuffleReadMetrics extends Serializable { /** * Total number of blocks fetched in a shuffle (remote or local) */ var totalBlocksFetched : Int = _ + /** * Number of remote blocks fetched in a shuffle */ var remoteBlocksFetched: Int = _ + /** * Local blocks fetched in a shuffle */ var localBlocksFetched: Int = _ + /** * Total time to read shuffle data */ var shuffleReadMillis: Long = _ + /** * Total time that is spent blocked waiting for shuffle to fetch remote data */ var remoteFetchWaitTime: Long = _ + /** * The total amount of time for all the shuffle fetches. This adds up time from overlapping * shuffles, so can be longer than task time */ var remoteFetchTime: Long = _ + /** * Total number of remote bytes read from a shuffle */ var remoteBytesRead: Long = _ } -class ShuffleWriteMetrics { +class ShuffleWriteMetrics extends Serializable { /** * Number of bytes written for a shuffle */ var shuffleBytesWritten: Long = _ -}
\ No newline at end of file +} |