This is an automated email from the ASF dual-hosted git repository. srowen pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/spark.git
The following commit(s) were added to refs/heads/master by this push: new 05f6b87 [SPARK-27410][MLLIB] Remove deprecated / no-op mllib.KMeans getRuns, setRuns 05f6b87 is described below commit 05f6b87e8126b30e1b9dd2c43e8bbbb101919dea Author: Sean Owen <sean.o...@databricks.com> AuthorDate: Tue Apr 9 19:13:35 2019 -0500 [SPARK-27410][MLLIB] Remove deprecated / no-op mllib.KMeans getRuns, setRuns ## What changes were proposed in this pull request? Remove deprecated / no-op mllib.KMeans getRuns, setRuns mllib.KMeans has getRuns, setRuns methods which haven't done anything since Spark 2.1. They're deprecated, and no-ops, and should be removed for Spark 3. ## How was this patch tested? Existing tests. Closes #24320 from srowen/SPARK-27410. Authored-by: Sean Owen <sean.o...@databricks.com> Signed-off-by: Sean Owen <sean.o...@databricks.com> --- .../org/apache/spark/mllib/clustering/KMeans.scala | 21 --------------------- project/MimaExcludes.scala | 4 ++++ 2 files changed, 4 insertions(+), 21 deletions(-) diff --git a/mllib/src/main/scala/org/apache/spark/mllib/clustering/KMeans.scala b/mllib/src/main/scala/org/apache/spark/mllib/clustering/KMeans.scala index d2118c2..4bb79bc 100644 --- a/mllib/src/main/scala/org/apache/spark/mllib/clustering/KMeans.scala +++ b/mllib/src/main/scala/org/apache/spark/mllib/clustering/KMeans.scala @@ -22,7 +22,6 @@ import scala.collection.mutable.ArrayBuffer import org.apache.spark.annotation.Since import org.apache.spark.broadcast.Broadcast import org.apache.spark.internal.Logging -import org.apache.spark.ml.clustering.{KMeans => NewKMeans} import org.apache.spark.ml.util.Instrumentation import org.apache.spark.mllib.linalg.{Vector, Vectors} import org.apache.spark.mllib.linalg.BLAS.axpy @@ -122,26 +121,6 @@ class KMeans private ( } /** - * This function has no effect since Spark 2.0.0. - */ - @Since("1.4.0") - @deprecated("This has no effect and always returns 1", "2.1.0") - def getRuns: Int = { - logWarning("Getting number of runs has no effect since Spark 2.0.0.") - 1 - } - - /** - * This function has no effect since Spark 2.0.0. - */ - @Since("0.8.0") - @deprecated("This has no effect", "2.1.0") - def setRuns(runs: Int): this.type = { - logWarning("Setting number of runs has no effect since Spark 2.0.0.") - this - } - - /** * Number of steps for the k-means|| initialization mode */ @Since("1.4.0") diff --git a/project/MimaExcludes.scala b/project/MimaExcludes.scala index fb92dfa..2a5d01e 100644 --- a/project/MimaExcludes.scala +++ b/project/MimaExcludes.scala @@ -36,6 +36,10 @@ object MimaExcludes { // Exclude rules for 3.0.x lazy val v30excludes = v24excludes ++ Seq( + // [SPARK-27410][MLLIB] Remove deprecated / no-op mllib.KMeans getRuns, setRuns + ProblemFilters.exclude[DirectMissingMethodProblem]("org.apache.spark.mllib.clustering.KMeans.getRuns"), + ProblemFilters.exclude[DirectMissingMethodProblem]("org.apache.spark.mllib.clustering.KMeans.setRuns"), + // [SPARK-27090][CORE] Removing old LEGACY_DRIVER_IDENTIFIER ("<driver>") ProblemFilters.exclude[DirectMissingMethodProblem]("org.apache.spark.SparkContext.LEGACY_DRIVER_IDENTIFIER"), // [SPARK-25838] Remove formatVersion from Saveable --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@spark.apache.org For additional commands, e-mail: commits-h...@spark.apache.org