package depot import "context" type ProbeState int const ( Present ProbeState = iota Absent Unconfirmed ) // Backend defines the interface for blob storage backends. type Backend interface { // Name returns the backend name. Name() string // Probe returns the existence state of one sha. transient=true means a // retry might change the answer (feeds the serial confirm loop). Probe(ctx context.Context, sha string) (state ProbeState, transient bool, err error) // Get fetches sha into dest (temp file + rename), re-hashes, deletes on mismatch. Get(ctx context.Context, sha, dest string) error // Put uploads bytes from src for sha. Read-only backends return an error. Put(ctx context.Context, sha, src string) error }