Multiple databases or namespace in Hbase

后端 未结 3 861
爱一瞬间的悲伤
爱一瞬间的悲伤 2021-02-08 00:33

Is there a way to setup Hbase so we can create multiples databases inside the same cluster ?

3条回答
  •  野趣味
    野趣味 (楼主)
    2021-02-08 01:28

    Just to refresh topic: http://hbase.apache.org/book.html#namespace

    5.3.1. Namespace management A namespace can be created, removed or altered. Namespace membership is determined during table creation by specifying a fully-qualified table name of the form:

    : Example 5.1. Examples

    #Create a namespace
    create_namespace 'my_ns'
    
    #create my_table in my_ns namespace
    create 'my_ns:my_table', 'fam'
    
    #drop namespace
    drop_namespace 'my_ns'
    
    #alter namespace
    alter_namespace 'my_ns', {METHOD => 'set', 'PROPERTY_NAME' => 'PROPERTY_VALUE'}
    

提交回复
热议问题