Details
-
Bug
-
Status: Resolved
-
Major
-
Resolution: Fixed
-
connector-1.0.0
-
None
-
- HBase 2.2.4
- Hadoop 2.10.0
- Spark 2.4.5
Description
Defining the following table catalog:
val catalog = """{ |"table": {"namespace": "ns1", "name": "test1"}, |"rowkey": "id", |"columns": { |"id": {"cf": "rowkey", "col": "id", "type": "string"}, |"x": {"cf": "d", "col": "xxx", "type": "int"} |} |}""".stripMargin
Try to write some test data to ns1:test1 table using spark:
val df = Seq(("abc", 1), ("def", 2)).toDF("id", "x") df.write.options(Map(HBaseTableCatalog.tableCatalog -> catalog, "hbase.spark.use.hbasecontext" -> "false", HBaseTableCatalog.newTable-> "5")).format("org.apache.hadoop.hbase.spark").save()
After executing the code above, I found out that the test data was written to default:test1, rather than ns1:test1.
Attachments
Issue Links
- is related to
-
HBASE-27624 Cannot Specify Namespace via the hbase.table Option in Spark Connector
- Resolved
- links to