You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@spark.apache.org by Ted Yu <yu...@gmail.com> on 2016/09/06 19:42:48 UTC

Replacement for SparkSqlSerializer.deserialize[

Hi,
In hbase-spark module of hbase, we previously had this code:

  def hbaseFieldToScalaType(
      f: Field,
      src: Array[Byte],
      offset: Int,
      length: Int): Any = {
...
        case BinaryType =>
          val newArray = new Array[Byte](length)
          System.arraycopy(src, offset, newArray, 0, length)
          newArray
        // TODO: add more data type support
        case _ => SparkSqlSerializer.deserialize[Any](src)

SparkSqlSerializer is no longer accessible as of spark 2.0.

Is there replacement for it ?

Thanks