hyrise
hyrise copied to clipboard
Proper way to determine if a chunk can be finalized
Currently, we lack a proper way to determine if a chunk can be finalized (and thus encoded). That means that all transactions are either committed or rollbacked.
#2457 might or might not remove a job that checked it this way:
if (mvcc_data->get_begin_cid(chunk_offset) == MvccData::MAX_COMMIT_ID) return CHUNK_NOT_FINALIZABLE;
However, reading the non-atomic begin_cid might be UB.
One thing that might help here is to count (atomic_int or alikes) how many Insert operations are currently still being active (uncommitted, not yet rollbacked) per chunk.