hbase-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Suraj Varma <svarma...@gmail.com>
Subject Re: Problem with url encode for http rest CLIENT
Date Thu, 03 Nov 2011 08:04:45 GMT
You are running into encoding issues. Likely, you are posting data
that is not UTF-8 as UTF-8 (i.e. your post XML says cell value is
"utf-8" ... but it is not). This results in the data not being
recognized and replaced with ef bf bd which is the unicode replacement
character; Google for "ef bf bd unicode" for a lot of links related to

Solution would be to convert your data into utf-8 before posting.

On Wed, Oct 26, 2011 at 4:17 PM, ChongQing Xiao <CqXiao@epic.com> wrote:
> Hi,
> I found a strange problem with http REST post.
> I post a dat through the following URL
> "/AAA/1000_1_100_%00%00%00d%00%06%1A%80/D:V"
> and it works correctly, but when I query the same address using get,
> I get the following xml result
> <?xml version="1.0" encoding="UTF-8" standalone="yes"?><CellSet><Row key="MTAwMF
> 8xXzEwMF8AAABkAAYa77+9"><Cell timestamp="1319664990595" column="RDpW">YWRi</Cell
> The problem is if I decode the key, it is different from my post URL
> "/AAA/1000_1_100_%00%00%00%64%00%06%1A%EF%BF%BD/D:V
> The same key displays from the hbase shell.
> Somehow, the %80 is translated to %EF%BF%BD,
> The strange thing is I can still get the same data using both of the URLs.
> I am using the stable version 0.9.04.
> Does anyone know what is causing this?
> Any suggestion will be greatly appreciated.
> Thanks
> Chong

View raw message