hbase-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ryan Rawson <ryano...@gmail.com>
Subject Re: Data format in HBase
Date Wed, 26 Jan 2011 09:57:31 GMT
Check out the bytes utility class had methods for converting songs to byte
arrays and vice versa. If you have numeric data, you can save on space by
using the Bytes.toBytes(int) etc calls, instead of converting to string
first. This can make it a bit harder top display in the shell since it will
look like a hex dump not a number, but consider a long can have 19 decimal
digits, but only takes up 8 bytes, you can see the attraction.

At su we use binary storage, but it does make hive interop a little harder.
But the savings can be substantial!
On Jan 26, 2011 1:47 AM, "Eric" <eric.xkcd@gmail.com> wrote:
> I'm wondering what the best way is to store my data in HBase. I'm
> converting everything to a string and then to a bytes array.
> What are others doing? Plain text to to byte arrays and eventually convert
> your data back to floats, int, etcetera?

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message