This is an automated email from the ASF dual-hosted git repository. gurwls223 pushed a commit to branch branch-3.1 in repository https://gitbox.apache.org/repos/asf/spark.git
The following commit(s) were added to refs/heads/branch-3.1 by this push: new 26847627239 Revert "[MINOR][SQL][SS][DOCS] Add varargs to Dataset.observe(String, ..) with a documentation fix" 26847627239 is described below commit 268476272399df6253b47112d5c2830cfdc5aef6 Author: Hyukjin Kwon <gurwls...@apache.org> AuthorDate: Thu Apr 7 09:44:36 2022 +0900 Revert "[MINOR][SQL][SS][DOCS] Add varargs to Dataset.observe(String, ..) with a documentation fix" This reverts commit dea607fc6040fc9f252632b6c73d5948ada02a98. --- sql/core/src/main/scala/org/apache/spark/sql/Dataset.scala | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/sql/core/src/main/scala/org/apache/spark/sql/Dataset.scala b/sql/core/src/main/scala/org/apache/spark/sql/Dataset.scala index c8d9725b0bc..0d6fde3101f 100644 --- a/sql/core/src/main/scala/org/apache/spark/sql/Dataset.scala +++ b/sql/core/src/main/scala/org/apache/spark/sql/Dataset.scala @@ -1935,7 +1935,6 @@ class Dataset[T] private[sql]( * {{{ * // Monitor the metrics using a listener. * spark.streams.addListener(new StreamingQueryListener() { - * override def onQueryStarted(event: QueryStartedEvent): Unit = {} * override def onQueryProgress(event: QueryProgressEvent): Unit = { * event.progress.observedMetrics.asScala.get("my_event").foreach { row => * // Trigger if the number of errors exceeds 5 percent @@ -1947,7 +1946,8 @@ class Dataset[T] private[sql]( * } * } * } - * override def onQueryTerminated(event: QueryTerminatedEvent): Unit = {} + * def onQueryStarted(event: QueryStartedEvent): Unit = {} + * def onQueryTerminated(event: QueryTerminatedEvent): Unit = {} * }) * // Observe row count (rc) and error row count (erc) in the streaming Dataset * val observed_ds = ds.observe("my_event", count(lit(1)).as("rc"), count($"error").as("erc")) @@ -1957,7 +1957,6 @@ class Dataset[T] private[sql]( * @group typedrel * @since 3.0.0 */ - @varargs def observe(name: String, expr: Column, exprs: Column*): Dataset[T] = withTypedPlan { CollectMetrics(name, (expr +: exprs).map(_.named), logicalPlan) } --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@spark.apache.org For additional commands, e-mail: commits-h...@spark.apache.org