hbase-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Cosmin Lehene <cleh...@adobe.com>
Subject Why doesn't KeyValue.equals/CellComparator compare the values?
Date Thu, 27 Feb 2014 03:25:02 GMT
I'm assuming is for performance reasons and a tradeoff against complicating some use-cases
with collections if done differently.

However as Cell and CellComparator is part of the API it also get's used in collections and
the implicit expectation is that it will compare the value as well (I.e. This has potential
for some interesting bugs... Yes I got bitten by it :)).

Also this doesn't even get mentioned in Cell.equals(Cell, Cell) javadoc and the only mention
is in KeyValue.equals ("Needed doing 'contains' on List.  Only compares the key portion, not
the value.").

I saw CellUtil.matchingValue and  Result.compareResults could potentially be used, however
I'm trying to understand the full context.

I looked over https://issues.apache.org/jira/browse/HBASE-4676 and https://issues.apache.org/jira/browse/HBASE-7162
which seem to introduce the comparison code, but I couldn't find something explicit so I thought
that this may have older origins.


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