Fixed TableMutator::set_cells to throw BAD_KEY exception for cf/cell deletes without a column family.

0 views
Skip to first unread message

Sanjit Jhala

unread,
Oct 16, 2009, 12:53:23 AM10/16/09
to hypertable-...@googlegroups.com
Fixed TableMutator::set_cells to throw BAD_KEY exception for cf/cell 
deletes without a column family.

http://github.com/sjhalaz/hypertable/commit/b35969789a449b668182e509c9c36c06d33727ef

-Sanjit

Luke

unread,
Oct 16, 2009, 11:08:28 AM10/16/09
to hypertable-...@googlegroups.com
lgtm. We'll probably need to revisit, once we allow row only tables.

Doug Judd

unread,
Oct 16, 2009, 1:07:35 PM10/16/09
to hypertable-...@googlegroups.com
Wasn't this causing the RangeServer to crash?  If so, there should be a sanity check inside the RangeServer that throws an exception if it encounters a bad column family.

- Doug

On Thu, Oct 15, 2009 at 9:53 PM, Sanjit Jhala <sjh...@gmail.com> wrote:

Sanjit Jhala

unread,
Oct 19, 2009, 7:43:15 PM10/19/09
to hypertable-...@googlegroups.com
Fixed TableMutator::set_cells to throw BAD_KEY exception for cf/cell 
deletes without a column family.

-Added checks in Client and RangeServer
-Replaced HT_ASSERT with HT_THROW in case of garbage control flag in key

http://github.com/sjhalaz/hypertable/commit/d8210cc87569b3f3540736bc6b9e07a504914e72

-Sanjit

Luke

unread,
Oct 19, 2009, 7:58:59 PM10/19/09
to hypertable-...@googlegroups.com
lg. I'd suggest that you use HT_TRY("filling key",
transform_key(...)); instead of
try {
transform_key(...);
}
HT_RETHROW_

As it's shorter and produce more informative backtrace.

Luke

unread,
Oct 19, 2009, 8:03:36 PM10/19/09
to hypertable-...@googlegroups.com
Since transform_key is only called in one place, the HT_TRY or
HT_RETHROW is not necessary. It could make things a little slower by
enlarging the code block with exception catch code, as transform_key
is called in a loop.

Sanjit Jhala

unread,
Oct 19, 2009, 8:49:53 PM10/19/09
to hypertable-...@googlegroups.com
Reply all
Reply to author
Forward
0 new messages