Grokbase Groups HBase dev April 2008
[ ]

Jim Kellerman updated HBASE-82:

Fix Version/s: 0.2.0

As this is an API change, it should go into 0.2.0
[hbase] VOTE: should row keys be less restrictive than

Key: HBASE-82
Project: Hadoop HBase
Issue Type: Wish
Reporter: Jim Kellerman
Assignee: stack
Fix For: 0.2.0

I have heard from several people that row keys in HBase should be less restricted than
What do you think?
At the very least, a row key has to be a WritableComparable. This would lead to the most general case being either or The primary difference between these two classes is that by default allocates 100 bytes and if you do not pay attention to the length, (BytesWritable.getSize()), converting a String to a BytesWritable and vice versa can become problematic., in contrast only allocates as many bytes as you pass in and then does not allow the size to be changed.
If we were to change from Text to a non-text key, my preference would be for ImmutableBytesWritable, because it has a fixed size once set, and operations like get, etc do not have to something like System.arrayCopy where you specify the number of bytes to copy.
Your comments, questions are welcome on this issue. If we receive enough feedback that Text is too restrictive, we are willing to change it, but we need to hear what would be the most useful thing to change it to as well.
This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

Search Discussions

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
groupdev @
categorieshbase, hadoop
postedApr 23, '08 at 10:34p
activeApr 23, '08 at 10:34p

1 user in discussion

Jim Kellerman (JIRA): 1 post



site design / logo © 2022 Grokbase