How to process a range of hbase rows using spark?

后端 未结 3 726
無奈伤痛
無奈伤痛 2021-02-04 14:04

I am trying to use HBase as a data source for spark. So the first step turns out to be creating a RDD from a HBase table. Since Spark works with hadoop input formats, i could fi

3条回答
  •  面向向阳花
    2021-02-04 14:28

    You can set below conf

     val conf = HBaseConfiguration.create()//need to set all param for habse
     conf.set(TableInputFormat.SCAN_ROW_START, "row2");
     conf.set(TableInputFormat.SCAN_ROW_STOP, "stoprowkey");
    

    this will load rdd only for those reocrds

提交回复
热议问题