Skip to content

V2 segment file should contain no more than INT32_MAX rows #1647

@gaodayue

Description

@gaodayue

Current V2 segment file allows more than INT32_MAX rows, it uses uint64_t to represent row count both in segment_v2::SegmentWriter and SegmentFooterPB. However bitmap implementations usually only support 32 bits integer, thus in order to support bitmap index later, we should limit row count in each segment to INT32_MAX.

Note that I deliberately choose INT32_MAX instead of UINT32_MAX to avoid overflow issue when casting from uint32_t to signed int.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions