Skip to main content

Crate griz_store

Crate griz_store 

Source
Expand description

Durable journal, locks, and recovery for griz edits.

The store is the only part of griz that writes source files. Every write is journaled as applying before the first rename, so an interrupted apply is finished by the next process that opens the store.

Structs§

Absorbed
What an absorb did.
ApplyRequest
How to apply a plan.
ConflictRegion
A conflicting line range in current, 1-based and inclusive.
FileWrite
One file an operation writes.
MergeConflict
One file a merge attempt could not resolve, carrying every text a caller needs to look at: base, planned, and current are blob identifiers readable with get.
Operation
One apply or undo.
Page
One page of operations, newest first.
PathResolver
Directory and file-alias identities retained for one batch of paths.
PlanRecord
A stored plan.
RestoreScope
The tree a restore is scoped to: root bounds the span first; paths narrows it further within that root.
Restores
The span an undo restored in one operation.
Selection
Which part of a plan to keep.
Store
Durable griz state for one home directory.
UndoRequest
How to undo an operation.

Enums§

Claim
What a key already means.
OnStale
What to do when a file changed after it was planned.
OperationKind
What an operation did. What an operation did.
OperationState
Where an operation is in its life.
StoreError
Why a store call failed.

Constants§

HOME_ENV
Environment variable naming the state directory.

Functions§

blob_id
The addressable identifier for the blob with fingerprint hash.
destination_path
Resolves a write’s parent directory, retaining its final directory entry.
directory_path
Resolves existing directory aliases, retaining a missing directory suffix.
parse_blob_id
The fingerprint id addresses, when it is a blob identifier.