Interface RegionedColumnSource<DATA_TYPE>

All Superinterfaces:
ChunkSource<Attributes.Values>, ChunkSource.WithPrev<Attributes.Values>, ColumnSource<DATA_TYPE>, DefaultChunkSource<Attributes.Values>, DefaultChunkSource.WithPrev<Attributes.Values>, ElementSource<DATA_TYPE>, FillContextMaker, GetContextMaker, ImmutableColumnSource<DATA_TYPE>, LongSizedDataStructure, Releasable, SizedColumnSource<DATA_TYPE>, TupleExporter<DATA_TYPE>, TupleSource<DATA_TYPE>
All Known Implementing Classes:
RegionedColumnSourceObject, RegionedColumnSourceObject.AsValues, RegionedColumnSourceObjectWithDictionary

@VisibleForTesting
public interface RegionedColumnSource<DATA_TYPE>
extends ImmutableColumnSource<DATA_TYPE>, SizedColumnSource<DATA_TYPE>

Regioned column source interface.

"V2" SourceTables can be thought of a tree of partitions with TableLocations at the leaf nodes. When building the Index for such a Table, we statically partition the available element address space from [0, 9223372036854775807L (2^63-1)].

We constrain the size at these leaf nodes in order to support a partitioning of the element address space into region index and sub-region element index. In order to make the calculations as inexpensive as possible, this is done by assigning X bits of each index key (element address) to the region index, and the remaining Y = 63 - X to the sub-region element index.

This type of address space allocation allows very cheap O(1) element access. Denser alternatives tend to introduce more complication and/or O(log n) lookups.

Currently, X is 23 and Y is 40, allowing tables to consist of more than 8 million locations with more than 1 trillion elements each.