Class BitmapValueIndexMaintainer


  • @API(EXPERIMENTAL)
    public class BitmapValueIndexMaintainer
    extends StandardIndexMaintainer
    An index maintainer for storing bitmaps of which records meet a specific condition.

    The index is defined on a position field, grouped by zero or more value conditions. The position should be an integer that is unique and reasonably dense, since compression of the index is traded off in favor of simplicity and concurrent updates. If the position is not set, then the item is not indexed at all.

    Instead of one key per record, the index stores one bit per record in a fixed-size bitmap aligned on even multiples of the position key.

    The position bitmaps behave as aggregate functions additionally grouped by ranges of the position.

    A unique option means that the index checks uniqueness of the position, with the expense of an additional read at update time. Also, when a uniqueness violation does occur, it is not possible to know what other record caused it. A separate unique index on the position field, if it is not the primary key, is therefore generally preferable.