Versions in this module Expand all Collapse all v0 v0.46.1 Sep 2, 2026 v0.46.0 Sep 1, 2026 Changes in this version + var ErrProjectLeaseCoverage = errors.New("project mutation requires a covering project lease") + var ErrSynchronizationAttempted = errors.New("project mutation synchronization already attempted") + var ErrTrackedLeaseCoverage = errors.New("project mutation requires a covering tracked lease") + func Finish[T any](outcome T, operationErr, releaseErr error, committed func(T) bool, ...) error + func Promote[T any](outcome T, err error, phase Phase, committed func(T) bool, ...) error + type Failure struct + Cause error + Phase Phase + func (e *Failure) Error() string + func (e *Failure) Unwrap() error + type LeaseAcquirer func(context.Context, string) (*filesystem.Lease, func() error, error) + type Partial struct + Cause error + Outcome T + Recovery []string + func NewPartial[T any](outcome T, cause error, recovery []string) Partial[T] + func (e *Partial[T]) Error() string + func (e *Partial[T]) JoinCause(err error) + func (e *Partial[T]) Unwrap() error + type Phase string + const PhaseAuthority + const PhaseCleanup + const PhaseLease + const PhasePublication + const PhaseRelease + const PhaseReload + func FailurePhase(err error) (Phase, bool) + type Scope uint8 + const ProjectScope + const TrackedScope + type Transaction struct + func AcquireProject(ctx context.Context, root string, loader *project.Loader, ...) (*Transaction, error) + func UseProject(ctx context.Context, root string, loader *project.Loader, ...) (*Transaction, error) + func UseTracked(ctx context.Context, root string, loader *project.Loader, ...) (*Transaction, error) + func (t *Transaction) LoadAuthority() (*project.Session, error) + func (t *Transaction) LoadForMutation(files *filesystem.Handle) (*project.Session, *filesystem.ExpectedIdentity, error) + func (t *Transaction) Open() (*filesystem.Handle, error) + func (t *Transaction) Release() error + func (t *Transaction) Root() string + func (t *Transaction) Scope() Scope + func (t *Transaction) Synchronize() (publisher.Result, error)