Skip to content

Commit

Permalink
Added MIMA excludes for VectorUDT (now public), and added DeveloperAp…
Browse files Browse the repository at this point in the history
…i annotation to it
  • Loading branch information
jkbradley committed Feb 5, 2015
1 parent 216d199 commit f542997
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ import scala.collection.JavaConverters._
import breeze.linalg.{DenseVector => BDV, SparseVector => BSV, Vector => BV}

import org.apache.spark.SparkException
import org.apache.spark.annotation.DeveloperApi
import org.apache.spark.mllib.util.NumericParser
import org.apache.spark.sql.Row
import org.apache.spark.sql.catalyst.expressions.GenericMutableRow
Expand Down Expand Up @@ -110,9 +111,12 @@ sealed trait Vector extends Serializable {
}

/**
* :: DeveloperApi ::
*
* User-defined type for [[Vector]] which allows easy interaction with SQL
* via [[org.apache.spark.sql.DataFrame]].
*/
@DeveloperApi
class VectorUDT extends UserDefinedType[Vector] {

override def sqlType: StructType = {
Expand Down
5 changes: 5 additions & 0 deletions project/MimaExcludes.scala
Original file line number Diff line number Diff line change
Expand Up @@ -143,6 +143,11 @@ object MimaExcludes {
"org.apache.spark.graphx.Graph.getCheckpointFiles"),
ProblemFilters.exclude[MissingMethodProblem](
"org.apache.spark.graphx.Graph.isCheckpointed")
) ++ Seq(
// SPARK-4789 Standardize ML Prediction APIs
ProblemFilters.exclude[MissingTypesProblem]("org.apache.spark.mllib.linalg.VectorUDT"),
ProblemFilters.exclude[IncompatibleResultTypeProblem]("org.apache.spark.mllib.linalg.VectorUDT.serialize"),
ProblemFilters.exclude[IncompatibleResultTypeProblem]("org.apache.spark.mllib.linalg.VectorUDT.sqlType")
)

case v if v.startsWith("1.2") =>
Expand Down

0 comments on commit f542997

Please sign in to comment.