kite-sdk/kite — pull request #28 by rdblue (2014-03-06 06:37:48+00:00)
Title: CDK-195: Fix identical partition names for Hive.

This fixes compatibility with Hive by renaming partitions so that the
partition name does not match the source field name. Defaults are added
to all of the FieldPartitioner implementations, except for identity
which now requires both source and partition names.

All field partitioners created with only one name will now use a
default partition name based on the source name, such as "color_hash"
for the "color" source field. All data will be written using these new
names and is compatible with Hive.

Backward-compatibility is maintained because the partition iterator will
ignore partition names, see TestPartitionIteratorTolerance.

The PartitionStrategy.Builder now constructs partitioners directly
rather than using PartitionFunctions so that PartitionFunctions can be
maintained separately because it has different compatibility concerns.
The Builder's deprecated identity method has been removed and a new
method added that uses both source and partition names.

PartitionFunctions still defines all previously used functions, which
are needed to parse partition strategies serialized by older versions.
This also fixes a bug in the range partition serialization, which did
not previously work.