Skip to content

CheckpointMaintenance

Defined in: packages/core/src/history/checkpointRetention.ts:730

The maintenance commands’ handle on one store, or null when there is nothing there. Fail-soft in the same shape as openHistoryStore / openCheckpointSaver, and it never CREATES a store: gth history prune on a machine with no history should say there is none, not leave an empty store behind. It does split a single-file store, like every other open.

bytesOf(threadIds): number

Defined in: packages/core/src/history/checkpointRetention.ts:762

Bytes stored under exactly these threads — what removing them would reclaim.

readonly string[]

number


close(): void

Defined in: packages/core/src/history/checkpointRetention.ts:771

void


diskBytes(): number

Defined in: packages/core/src/history/checkpointRetention.ts:767

The bytes the store occupies on disk, for the before/after of a prune.

number


prunable(bounds): PrunableConversation[]

Defined in: packages/core/src/history/checkpointRetention.ts:744

PruneBounds

PrunableConversation[]


remove(threadIds): ReclaimSummary

Defined in: packages/core/src/history/checkpointRetention.ts:757

readonly string[]

ReclaimSummary


stats(topN?): CheckpointStoreStats

Defined in: packages/core/src/history/checkpointRetention.ts:740

number = DEFAULT_TOP_THREADS

CheckpointStoreStats


unaddressable(options?): string[]

Defined in: packages/core/src/history/checkpointRetention.ts:748

number

number

string[]


writeOnly(options?): string[]

Defined in: packages/core/src/history/checkpointRetention.ts:753

GS2-108 — threads holding pending writes and no checkpoint, which only a prune reclaims.

readonly string[]

string[]


static open(storePath): CheckpointMaintenance | null

Defined in: packages/core/src/history/checkpointRetention.ts:733

string

CheckpointMaintenance | null