Home | About | Sematext search-lucene.com search-hadoop.com
 Search Hadoop and all its subprojects:

Switch to Threaded View
HBase >> mail # user >> REST API Table Create ColumnSchema Ignored


Copy link to this message
-
Re: REST API Table Create ColumnSchema Ignored
Can you check the server log around the time you issued the PUT command ?

I am not familiar with REST. But are the square brackets required ?

Cheers

On Sat, Mar 2, 2013 at 4:36 PM, Ben Myles <[EMAIL PROTECTED]> wrote:

> Trying to create a table using the REST API. Here's my curl request:
>
> curl -v -X PUT \
>   'http://cdh45:20550/curltest/schema' \
>   -H "Accept: application/json" \
>   -H "Content-Type: application/json" \
>   -d '{"name":"curltest","ColumnSchema":[{"name":"data", "COMPRESSION":
> "GZ"}]}'
>
> This creates the table 'curliest' with the column family 'data'. Problem
> is, it doesn't set COMPRESSION (or any other options I pass):
>
> hbase(main):020:0> describe 'curltest'
> DESCRIPTION
>                                                       ENABLED
>
>  {NAME => 'curltest', FAMILIES => [{NAME => 'data', DATA_BLOCK_ENCODING =>
> 'NONE', BLOOMFILTER => 'NONE', REPLICATION_SCOPE => '0 true
>
>  ', VERSIONS => '3', COMPRESSION => 'NONE', MIN_VERSIONS => '0', TTL =>
> '2147483647', KEEP_DELETED_CELLS => 'false', BLOCKSIZE =>
>
>   '65536', IN_MEMORY => 'false', ENCODE_ON_DISK => 'true', BLOCKCACHE =>
> 'true'}]}
>
>
> Am I just formatting this wrong, or is this a known bug?
>
> HBase version: 0.94.2-cdh4.2.0
>
> Thanks!
>