Skip to content

force_checkpoint broken #7

@gabrielbornstein

Description

@gabrielbornstein

KVStore::force_checkpoint is not guaranteed to flush all the keys that have been taken.

BATT_REQUIRE_OK(this->deltas_size_->await_true([this](usize n) {
    return n < 2;
  }));``

The above statement highlights that force_checkpoint waits until there is one key left, so it may be the case we won't create a checkpoint if there is more than one key not flushed. We want to change this dependency from checking if keys are flushed to something correlated to the checkpoint's upper bound, verifying that the checkpoint has finished.

If this value is made to be less the one key, we fail in other cases, specifically if we attempt to take a checkpoint when there are no keys in the database.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions