booblik
Wiki

dev/common

Generated page

Model gemma-mtp, commit f508a4b65b3f, 2026-08-16, sources: 2. Edit the code or the hand-written documentation instead.

Diagram

FileOffsetStore

The primary implementation of the OffsetStore interface using the local filesystem, as seen in FileOffsetStore.kt:27.

More: FileOffsetStore

Atomic offset persistence

The mechanism of writing offsets via temporary files and atomic moves to prevent data corruption, implemented in FileOffsetStore.kt:55-57.

More: Atomic offset persistence

load and save operations

The lifecycle of reading and writing offsets for a specific TopicName and PartitionId, handled by the load and save methods in FileOffsetStore.kt:34-58.

Key files

FileLinesWhat is there
…/common/FileOffsetStore.kt27-64The implementation of the FileOffsetStore class and its file-based logic.

Public API

WhatWhereWhy
FileOffsetStoreFileOffsetStore.kt:27Provides a filesystem-based implementation of the OffsetStore interface.

Behaviour that surprise

  • save uses a temporary file and an atomic move (FileOffsetStore.kt:55-57) to ensure that a partially written offset does not corrupt the state.
  • load returns null if the offset file does not exist on the disk (FileOffsetStore.kt:40).

On this page