removeEntryFor method

  1. @override
  2. @server
Future<void> removeEntryFor(
  1. String key
)
override

key is utf7-decoded first, matching commit's treatment, so callers pass the same (encoded) form to both. Routes through HiveCommitLogKeyStore.remove, which also evicts the entry from the in-memory cache map.

Implementation

@override
@server
Future<void> removeEntryFor(String key) async {
  key = Utf7.decode(key);
  final CommitEntry? entry = _commitLogKeyStore.getLatestCommitEntry(key);
  if (entry?.commitId != null) {
    await _commitLogKeyStore.remove(entry!.commitId!);
  }
}