更新时间:2023-06-20 GMT+08:00
分享

使用REST获取所有表

功能简介

使用REST服务,传入对应host与port组成的url,通过HTTP协议,获取得到所有table。

代码样例

以下代码片段在“hbase-rest-example\src\main\java\com\huawei\hadoop\hbase\examples”包的“HBaseRestTest”类的getAllUserTables方法中。
private void getAllUserTables(String url) {
     String endpoint = "/";
     Optional<ResultModel> result = sendAction(url + endpoint, MethodType.GET, null);
     handleNormalResult(result);
 }
分享:

    相关文档

    相关产品