You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by GitBox <gi...@apache.org> on 2019/12/19 15:16:28 UTC
[GitHub] [spark] LucaCanali opened a new pull request #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
metrics using Spark Metrics system
LucaCanali opened a new pull request #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953
### What changes were proposed in this pull request?
This proposes to extend Spark instrumentation to add metrics aimed at drilling down on the performance of Python code called by Spark: via UDF, Pandas UDF or with MapPartittions. Relevant performance counters, notably exuction time, are exposed using the Spark Metrics System (based on the Dropwizard library).
### Why are the changes needed?
This allows to easily consume the metrics produced by executors, for example using a performance dashboard (this references to previous work as discucssed in https://db-blog.web.cern.ch/blog/luca-canali/2019-02-performance-dashboard-apache-spark ).
See also the screenshot that compares the existing state (no Python UDF time instrumentation) to the proposed new functionality 
### Does this PR introduce any user-facing change?
This PR adds the PythonMetrics source to the Spark Metrics system. The list of the implemented metrics has been added to the Monitoring documentation.
### How was this patch tested?
Added relevant tests
+ manually tested end-to-end on a YARN cluster and using an existing Spark dashboard extended with the metrics proposed here.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-575464575
Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/21663/
Test PASSed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA removed a comment on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
SparkQA removed a comment on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-579142327
**[Test build #117475 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/117475/testReport)** for PR 26953 at commit [`af34f49`](https://github.com/apache/spark/commit/af34f49d5f8d46610f195541c171313317accf6f).
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-575512706
Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/116893/
Test PASSed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
SparkQA commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-589593065
**[Test build #118782 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/118782/testReport)** for PR 26953 at commit [`fd76071`](https://github.com/apache/spark/commit/fd760714b41254d721393e10501d074e57a93aa2).
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-579207543
Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/117475/
Test PASSed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-614057560
Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/26011/
Test PASSed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-589639955
Merged build finished. Test FAILed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-614143008
Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/121328/
Test PASSed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-595084204
Merged build finished. Test FAILed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] HyukjinKwon commented on a change in pull request #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
HyukjinKwon commented on a change in pull request #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#discussion_r360286954
##########
File path: core/src/main/scala/org/apache/spark/api/python/PythonMetrics.scala
##########
@@ -0,0 +1,179 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.spark.api.python
+
+import java.util.concurrent.atomic.AtomicLong
+
+private[spark] object PythonMetrics {
+
+ // Instrument with general metrics on serialization/deserialization JVM-to-Python
+ private val ToWorkerWriteTime = new AtomicLong(0L)
+ private val ToWorkerBatchCount = new AtomicLong(0L)
+ private val ToWorkerBytesWritten = new AtomicLong(0L)
+ private val FromWorkerReadTime = new AtomicLong(0L)
+ private val FromWorkerBatchCount = new AtomicLong(0L)
+
+ // Instrument Map Partitions operations
+ private val MapPartitionReadTime = new AtomicLong(0L)
+ private val MapPartitionReadBatchCount = new AtomicLong(0L)
+ private val MapPartitionBytesRead = new AtomicLong(0L)
+
+ // Instrument Python UDF
+ private val UDFReadTime = new AtomicLong(0L)
+ private val UDFReadBatchCount = new AtomicLong(0L)
+ private val UDFBytesRead = new AtomicLong(0L)
+
+ // Instrument Pandas_UDF
+ private val pandasUDFReadTime = new AtomicLong(0L)
+ private val pandasUDFReadBatchCount = new AtomicLong(0L)
+ private val pandasUDFWriteBatchCount = new AtomicLong(0L)
+ private val pandasUDFReadRowCount = new AtomicLong(0L)
+ private val pandasUDFWriteRowCount = new AtomicLong(0L)
+
+ def incToWorkerWriteTime(delta: Long): Unit = {
+ ToWorkerWriteTime.getAndAdd(delta)
+ }
+
+ def getToWorkerWriteTime: Long = {
+ ToWorkerWriteTime.get
+ }
+
+ def incToWorkerBytesWritten(delta: Long): Unit = {
+ ToWorkerBytesWritten.getAndAdd(delta)
+ }
+
+ def getToWorkerBytesWritten: Long = {
+ ToWorkerBytesWritten.get
+ }
+
+ def incToWorkerBatchCount(delta: Long): Unit = {
+ ToWorkerBatchCount.getAndAdd(delta)
+ }
+
+ def getToWorkerBatchCount: Long = {
+ ToWorkerBatchCount.get
+ }
+
+ def incFromWorkerReadTime(delta: Long): Unit = {
+ FromWorkerReadTime.getAndAdd(delta)
+ }
+
+ def getFromWorkerReadTime: Long = {
+ FromWorkerReadTime.get
+ }
+
+ def incFromWorkerBatchCount(delta: Long): Unit = {
+ FromWorkerBatchCount.getAndAdd(delta)
+ }
+
+ def getFromWorkerBatchCount: Long = {
+ FromWorkerBatchCount.get
+ }
+
+ // Map Partitions
+ def incMapPartitionReadTime(delta: Long): Unit = {
Review comment:
Can we just combine mapPartitions, pandas UDF and Python UDFs into single? e.g. python execution.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] LucaCanali commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
LucaCanali commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-590773929
retest this please
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-591006744
Merged build finished. Test PASSed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
SparkQA commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-614141845
**[Test build #121328 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/121328/testReport)** for PR 26953 at commit [`812ea5e`](https://github.com/apache/spark/commit/812ea5ec52c54aeee554e5df0e0d5dd8590b166f).
* This patch passes all tests.
* This patch merges cleanly.
* This patch adds no public classes.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-614057542
Merged build finished. Test PASSed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] HyukjinKwon commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
HyukjinKwon commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-575462770
ok to test
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-614142996
Merged build finished. Test PASSed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-595080190
Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/24110/
Test PASSed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-579207534
Merged build finished. Test PASSed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA removed a comment on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
SparkQA removed a comment on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-614056991
**[Test build #121328 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/121328/testReport)** for PR 26953 at commit [`812ea5e`](https://github.com/apache/spark/commit/812ea5ec52c54aeee554e5df0e0d5dd8590b166f).
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-595080190
Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/24110/
Test PASSed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-591006756
Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/23677/
Test PASSed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-595080181
Merged build finished. Test PASSed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-567546784
Can one of the admins verify this patch?
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] HyukjinKwon commented on a change in pull request #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
HyukjinKwon commented on a change in pull request #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#discussion_r367785615
##########
File path: core/src/main/scala/org/apache/spark/api/python/PythonRunner.scala
##########
@@ -434,7 +443,10 @@ private[spark] abstract class BasePythonRunner[IN, OUT](
override def hasNext: Boolean = nextObj != null || {
if (!eos) {
+ val startTime = System.nanoTime()
nextObj = read()
+ val deltaTime = System.nanoTime()-startTime
+ PythonMetrics.incFromWorkerReadTime(deltaTime)
Review comment:
Have a couple of questions.
- Is it possible to merge it with `SQLMetric`? It would be nicer if UI shows it as well.
- Is it possible to integrate with existing Python profiler? The current read time isn't purely Python execution time. It includes socket IO time which can potentially be large.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-579143431
Merged build finished. Test PASSed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
SparkQA commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-591006098
**[Test build #118929 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/118929/testReport)** for PR 26953 at commit [`fd76071`](https://github.com/apache/spark/commit/fd760714b41254d721393e10501d074e57a93aa2).
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-589639955
Merged build finished. Test FAILed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-579143439
Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/22234/
Test PASSed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-589639963
Test FAILed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/118782/
Test FAILed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-579207543
Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/117475/
Test PASSed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-579207534
Merged build finished. Test PASSed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-591006744
Merged build finished. Test PASSed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-575464575
Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/21663/
Test PASSed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-575464568
Merged build finished. Test PASSed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-595084214
Test FAILed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/119372/
Test FAILed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-595084204
Merged build finished. Test FAILed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA removed a comment on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
SparkQA removed a comment on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-575464231
**[Test build #116893 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/116893/testReport)** for PR 26953 at commit [`2d70042`](https://github.com/apache/spark/commit/2d700426f804efeecc36aac10870390bfebd2be8).
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
SparkQA commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-579206930
**[Test build #117475 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/117475/testReport)** for PR 26953 at commit [`af34f49`](https://github.com/apache/spark/commit/af34f49d5f8d46610f195541c171313317accf6f).
* This patch passes all tests.
* This patch merges cleanly.
* This patch adds no public classes.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-589593564
Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/23534/
Test PASSed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
SparkQA commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-579142327
**[Test build #117475 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/117475/testReport)** for PR 26953 at commit [`af34f49`](https://github.com/apache/spark/commit/af34f49d5f8d46610f195541c171313317accf6f).
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
SparkQA commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-591073364
**[Test build #118929 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/118929/testReport)** for PR 26953 at commit [`fd76071`](https://github.com/apache/spark/commit/fd760714b41254d721393e10501d074e57a93aa2).
* This patch **fails Spark unit tests**.
* This patch merges cleanly.
* This patch adds no public classes.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] LucaCanali edited a comment on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
LucaCanali edited a comment on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-567869272
Thanks @HyukjinKwon for taking time for this.
This functionality propoesed in ths PR is different from Python profiler, or at least its intended use is. Also it is intended to be lightweight so that it can be used for measuring Spark workloads in production as part of a performance dashboard based on the metrics coming from the Spark metrics system.
I'd like to add some additional context on how we intend to use this.
- I have described how we implement and use a Spark performance dashboard based on the metrics system in a recent Spark Summit presentation https://databricks.com/session_eu19/performance-troubleshooting-using-apache-spark-metrics and in a blog entry http://db-blog.web.cern.ch/blog/luca-canali/2019-02-performance-dashboard-apache-spark
- Over the last couple of years I have helped improving this by adding to the Spark metrics system instrumentation for aggregated task metrics values per executor [SPARK-25228], JVM CPU usage [SPARK-22190], memory usage [SPARK-27189]. This still does not cover all the space of possible activities and "time usage" by Spark tasks and executors, in particular the problem that I am trying to solve with this PR is that time spent waiting for results to come back from Python workers (typically when executing a UDF) is currently not instrumented, so it appears in the dashboard as run time "without attribution" in the current dashboard, while it can be visualized using the metrics implemented here (see [image](https://camo.githubusercontent.com/6bbade0b6d6dceeb75cea27a5041298a3132599c/68747470733a2f2f6973737565732e6170616368652e6f72672f6a6972612f7365637572652f6174746163686d656e742f31323938393230312f50616e6461735544465f54696d655f496e737472756d656e746174696f6e5f416e6e6f74617465642e706e67) )
As you mentioned, in the current PR I have implemented several details, which I guess can be useful when troubleshooting, but for the general use can be simplified as you propose, in particular in the number and detials exposed in the user-visible metrics in the PythonMetrics source.
A proposal for a simplified set of metrics to expose in the PythonMetrics source is:
- BatchCountFromWorker
- BatchCountToWorker
- BytesSentToWorker
- RunAndReadTimeFromWorker
- WriteTimeToWorker
- PandasUDFSentRowCount
- PandasUDFReceivedRowCount
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-591073762
Test FAILed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/118929/
Test FAILed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] LucaCanali commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
LucaCanali commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-572447865
This has now been streamlined down to the following metrics (under `namespace=PythonMetrics`):
- BytesReceivedFromWorkers
- BytesSentToWorkers
- FetchResultsTimeFromWorkers
- NumBatchesFromWorkers
- NumBatchesToWorkers
- PandasUDFReceivedNumRows
- PandasUDFSentNumRows
- WriteTimeToWorkers
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-575464568
Merged build finished. Test PASSed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA removed a comment on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
SparkQA removed a comment on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-595079598
**[Test build #119372 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/119372/testReport)** for PR 26953 at commit [`989dba1`](https://github.com/apache/spark/commit/989dba136ef6dc3d12a64765f524b19fe89af0ce).
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-591073758
Merged build finished. Test FAILed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
SparkQA commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-614056991
**[Test build #121328 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/121328/testReport)** for PR 26953 at commit [`812ea5e`](https://github.com/apache/spark/commit/812ea5ec52c54aeee554e5df0e0d5dd8590b166f).
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
SparkQA commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-589639560
**[Test build #118782 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/118782/testReport)** for PR 26953 at commit [`fd76071`](https://github.com/apache/spark/commit/fd760714b41254d721393e10501d074e57a93aa2).
* This patch **fails Spark unit tests**.
* This patch merges cleanly.
* This patch adds no public classes.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-579143431
Merged build finished. Test PASSed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-579143439
Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/22234/
Test PASSed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-589639963
Test FAILed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/118782/
Test FAILed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
SparkQA commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-575512053
**[Test build #116893 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/116893/testReport)** for PR 26953 at commit [`2d70042`](https://github.com/apache/spark/commit/2d700426f804efeecc36aac10870390bfebd2be8).
* This patch passes all tests.
* This patch merges cleanly.
* This patch adds no public classes.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-591073762
Test FAILed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/118929/
Test FAILed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-595084214
Test FAILed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/119372/
Test FAILed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-614142996
Merged build finished. Test PASSed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-591006756
Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/23677/
Test PASSed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
SparkQA commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-595079598
**[Test build #119372 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/119372/testReport)** for PR 26953 at commit [`989dba1`](https://github.com/apache/spark/commit/989dba136ef6dc3d12a64765f524b19fe89af0ce).
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] viirya commented on a change in pull request #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
viirya commented on a change in pull request #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#discussion_r410722181
##########
File path: core/src/main/scala/org/apache/spark/api/python/PythonMetrics.scala
##########
@@ -0,0 +1,101 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.spark.api.python
+
+import java.util.concurrent.atomic.AtomicLong
+
+private[spark] object PythonMetrics {
Review comment:
So, these metrics are incremental across all JVM-Python and Python UDFs in single Spark app?
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-575512692
Merged build finished. Test PASSed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-614057542
Merged build finished. Test PASSed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-589593564
Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/23534/
Test PASSed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] BryanCutler commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
BryanCutler commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-591004893
retest this please
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-575512706
Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/116893/
Test PASSed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-589593557
Merged build finished. Test PASSed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-591073758
Merged build finished. Test FAILed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA removed a comment on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
SparkQA removed a comment on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-591006098
**[Test build #118929 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/118929/testReport)** for PR 26953 at commit [`fd76071`](https://github.com/apache/spark/commit/fd760714b41254d721393e10501d074e57a93aa2).
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] LucaCanali commented on a change in pull request #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
LucaCanali commented on a change in pull request #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#discussion_r369652547
##########
File path: core/src/main/scala/org/apache/spark/api/python/PythonRunner.scala
##########
@@ -434,7 +443,10 @@ private[spark] abstract class BasePythonRunner[IN, OUT](
override def hasNext: Boolean = nextObj != null || {
if (!eos) {
+ val startTime = System.nanoTime()
nextObj = read()
+ val deltaTime = System.nanoTime()-startTime
+ PythonMetrics.incFromWorkerReadTime(deltaTime)
Review comment:
- I like the idea of adding SQLMetrics for Python UDF instrumentation and use them in the WEBUI. However, I think the work would rather fit for a separate JIRA/PR. The implementation details and the overhead of SQLMetrics are different from Dropwizard-based metrics, so probably we would like to have only a limited number of SQLMetrics instrumenting task activities in this area. Also the implementation of SQLMetrics for `[[PythonUDF]]` execution may require some important changes to the current plan evaluation code.
- It is indeed the case that the “read time from worker” which is exposed to the users via the dropwizard library as “FetchResultsTimeFromWorkers” contains both socket I/O + deserialization time and Python UDF execution time. Measuring on the Python side could allow to separate the 2 time components, however currently I don’t see how to make a lightweight implementation for that. Python profiler has the possibility to measure on the Python side as you mentioned, but I see its usage more for debugging, while the proposed instrumentation is lightweight and intended to be used for production use cases too. Maybe future work can address this case if there is need?
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-589593557
Merged build finished. Test PASSed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA removed a comment on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
SparkQA removed a comment on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-589593065
**[Test build #118782 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/118782/testReport)** for PR 26953 at commit [`fd76071`](https://github.com/apache/spark/commit/fd760714b41254d721393e10501d074e57a93aa2).
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-614143008
Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/121328/
Test PASSed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-614057560
Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/26011/
Test PASSed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] LucaCanali commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
LucaCanali commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-603811972
It looks like a case of flaky test. Can we test this again please?
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] LucaCanali commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
LucaCanali commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-567869272
Thanks @HyukjinKwon for taking time for this.
This functionality propoesed in ths PR is different from Python profiler, or at least its intended use is. Also it is intended to be lightweight so that it can be used for measuring Spark workloads in production as part of a performance dashboard based on the metrics coming from the Spark metrics system.
I'd like to add some additional context on how we intend to use this.
- I have described how we implement and use a Spark performance dashboard based on the metrics system in a recent Spark Summit presentation https://databricks.com/session_eu19/performance-troubleshooting-using-apache-spark-metrics and in a blog entry http://db-blog.web.cern.ch/blog/luca-canali/2019-02-performance-dashboard-apache-spark
- Over the last couple of years I have helped improving this by adding to the Spark metrics system instrumentation for aggregated task metrics values per executor [SPARK-25228], JVM CPU usage [SPARK-22190], memory usage [SPARK-27189]. This still does not cover all the space of possible activities and "time usage" by Spark tasks and executors, in particular the problem that I am trying to solve with this PR is that time spent waiting for results to come back from Python workers (typically when executing a UDF) is currently not instrumented, so it appears in the dashboard as run time "without attribution" in the current dashboard, while it can be visualized using the metrics implemented here (see [image](https://camo.githubusercontent.com/6bbade0b6d6dceeb75cea27a5041298a3132599c/68747470733a2f2f6973737565732e6170616368652e6f72672f6a6972612f7365637572652f6174746163686d656e742f31323938393230312f50616e6461735544465f54696d655f496e737472756d656e746174696f6e5f416e6e6f74617465642e706e67) )
As you mentioned, in the current PR I have implemented several details, which I guess can be useful when troubleshooting, but for the general use can be simplified as you propose, in particular in the number and detials exposed in the user-visible metrics in the PythonMetrics source.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-575512692
Merged build finished. Test PASSed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
SparkQA commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-575464231
**[Test build #116893 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/116893/testReport)** for PR 26953 at commit [`2d70042`](https://github.com/apache/spark/commit/2d700426f804efeecc36aac10870390bfebd2be8).
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
SparkQA commented on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-595084143
**[Test build #119372 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/119372/testReport)** for PR 26953 at commit [`989dba1`](https://github.com/apache/spark/commit/989dba136ef6dc3d12a64765f524b19fe89af0ce).
* This patch **fails due to an unknown error code, -9**.
* This patch merges cleanly.
* This patch adds no public classes.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on issue #26953:
[SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and
throughput metrics using Spark Metrics system
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on issue #26953: [SPARK-30306][CORE][PYTHON] Instrument Python UDF execution time and throughput metrics using Spark Metrics system
URL: https://github.com/apache/spark/pull/26953#issuecomment-595080181
Merged build finished. Test PASSed.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org