微信公众号搜"智元新知"关注
微信扫一扫可直接关注哦!

node-hbase-client [](<a href="https://github.com/alibaba/node-hbase-client#support-hbase-server-">https://github.com/alibaba/node-hbase-client#support-hbase-server-</a><a href="https://g

程序名称:node-hbase-client [](<a href="https://github.com/alibaba/node-hbase-client#support-hbase-server-">https://github.com/alibaba/node-hbase-client#support-hbase-server-</a><a href="https://g

授权协议: MIT

操作系统: 跨平台

开发语言: JavaScript

node-hbase-client [](<a href="https://github.com/alibaba/node-hbase-client#support-hbase-server-">https://github.com/alibaba/node-hbase-client#support-hbase-server-</a><a href="https://g 介绍

node-hbase-client 是 Node.js 的异步
HBase 客户端,使用纯 JavaScript 实现。

[](https://github.com/alibaba/node-hbase-client#support-hbase-server-

versions)支持 HBase 服务器的版本

  • [√] 0.94.x

    • [√] 0.94.0

    • [√] 0.94.16

  • 0.95.x

  • 0.96.x

安装

$ npm install hbase-client

使用

CRUD:

  • 通过 zookeeper 创建 HBase 客户端:

    var HBase = require(‘hbase-client’);var client = HBase.create({
      zookeeperHosts: [
        ‘127.0.0.1:2181’ // only local zookeeper
      ],
      zookeeperRoot: ’/hbase-0.94.16’,});

  • 输入

    client.putRow(‘soMetableName’, ‘rowkey1’, {‘f1:name’: ‘foo name’, ‘f1:age’: ‘18’}, function (err) {
      console.log(err);});

  • 获取

    client.getRow(‘soMetableName’, ‘rowkey1’, [‘f1:name’, ‘f1:age’], function (err, row) {
      console.log(row);});

  • 删除

    client.deleteRow(‘soMetableName’, ‘rowkey1’, function (err) {
      console.log(err);});

node-hbase-client [](<a href="https://github.com/alibaba/node-hbase-client#support-hbase-server-">https://github.com/alibaba/node-hbase-client#support-hbase-server-</a><a href="https://g 官网

https://github.com/alibaba/node-hbase-client

版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 [email protected] 举报,一经查实,本站将立刻删除。

相关推荐