accumulo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Keith Turner <>
Subject Re: feedback on Typo
Date Mon, 13 Aug 2012 16:55:34 GMT
On Mon, Aug 13, 2012 at 12:34 PM, Billie Rinaldi <> wrote:
> On Fri, Aug 10, 2012 at 8:07 PM, Keith Turner <> wrote:
>> I put together a simple abstraction layer for Accumulo that makes it
>> easier to read and write Java objects to Accumulo key and value
>> fields.  The data written to Accumulo sort correctly
>> lexicographically.
>> I put the code on github and would like some feedback on the design
>> and whether it should be included with Accumulo.
>> Its still a little rough and I need to add encoder for all of the
>> primitive types.
>> Keith
> Looks interesting.  It would be nice to have the TypedValueCombiner use the
> same Encoder, which leads to the question of where we should put this.  If

I agree, it would be nice for it share code w/ those iterators.
Also, it would be nice to have a DisplayFormatter and Constraint

> Typo is moved to contrib, perhaps the TypedValueCombiner should be there,
> too.  Another option might be a submodule of examples.  It would be nice to
> have a set of standard encodings shipped with Accumulo.
> I'd like to discuss the LexEncoder.  It is an Encoder that preserves sort

I am thinking of changing the name to Lexicoder.

> order, but it doesn't have a way to enforce or test the sorting, or even to
> encourage the preservation of sort order except through the javadoc.  Is
> there anything we can do about this?  We could at least make some reusable
> testing patterns, but it would be nice if we could do more.

If you have Lexicoder<A> and A is comparable, the we could provide
infrastructure to make it easy to write test that confirm they agree.
This could be completely automated if you could generate a good set of
representative data for type A.  For example, for Long we would at
least want to test that MIN, MIN+1, -1, 0, 1, MAX-1, and MAX sort
correctly lexicograpically and via the comparable interface.  I am not
sure how we would automatically generate this set of test data for an
arbitrary type though.  We could make running the test simple if
someone provides the data.

> Billie

View raw message